Facility

Facility Registry

This module facilitates the maintenance of a Facility registry.

Create/Add a new facility

post

Create a new facility

Body
Responses
202
Facility request has been accepted.
application/json
post
POST /facility/v1/_create HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 852

{
  "RequestInfo": {
    "apiId": "text",
    "ver": "text",
    "ts": 1,
    "action": "text",
    "did": "text",
    "key": "text",
    "msgId": "text",
    "requesterId": "text",
    "authToken": "text"
  },
  "Facility": {
    "tenantId": "tenantA",
    "isPermanent": true,
    "name": "Facility XYZ",
    "usage": "STORAGE_WAREHOUSE",
    "storageCapacity": 1,
    "address": {
      "tenantId": "tenantA",
      "doorNo": "text",
      "latitude": 1,
      "longitude": 1,
      "locationAccuracy": 1,
      "type": [
        "PERMANENT"
      ],
      "addressLine1": "text",
      "addressLine2": "text",
      "landmark": "text",
      "city": "text",
      "pincode": "text",
      "buildingName": "text",
      "street": "text",
      "locality": {
        "code": "text",
        "name": "text",
        "label": "text",
        "latitude": "text",
        "longitude": "text",
        "children": [
          {
            "code": "text",
            "name": "text",
            "label": "text",
            "latitude": "text",
            "longitude": "text",
            "children": "[Circular Reference]"
          }
        ]
      }
    },
    "additionalFields": {
      "schema": "HOUSEHOLD",
      "version": 2,
      "fields": [
        {
          "key": "height",
          "value": 180
        }
      ]
    },
    "rowVersion": 1
  }
}
{
  "ResponseInfo": {
    "apiId": "text",
    "ver": "text",
    "ts": 1,
    "resMsgId": "text",
    "msgId": "text",
    "status": "SUCCESSFUL"
  },
  "Facility": {
    "id": "text",
    "tenantId": "tenantA",
    "isPermanent": true,
    "name": "Facility XYZ",
    "usage": "STORAGE_WAREHOUSE",
    "storageCapacity": 1,
    "address": {
      "id": "text",
      "tenantId": "tenantA",
      "doorNo": "text",
      "latitude": 1,
      "longitude": 1,
      "locationAccuracy": 1,
      "type": [
        "PERMANENT"
      ],
      "addressLine1": "text",
      "addressLine2": "text",
      "landmark": "text",
      "city": "text",
      "pincode": "text",
      "buildingName": "text",
      "street": "text",
      "locality": {
        "code": "text",
        "name": "text",
        "label": "text",
        "latitude": "text",
        "longitude": "text",
        "children": [
          {
            "code": "text",
            "name": "text",
            "label": "text",
            "latitude": "text",
            "longitude": "text",
            "children": "[Circular Reference]",
            "materializedPath": "text"
          }
        ],
        "materializedPath": "text"
      }
    },
    "additionalFields": {
      "schema": "HOUSEHOLD",
      "version": 2,
      "fields": [
        {
          "key": "height",
          "value": 180
        }
      ]
    },
    "isDeleted": true,
    "rowVersion": 1,
    "auditDetails": {
      "createdBy": "text",
      "lastModifiedBy": "text",
      "createdTime": 1,
      "lastModifiedTime": 1
    }
  }
}

Create/Add new facilities in bulk

post

Create a new facilities in bulk

Body
Responses
202
Facility request has been accepted.
application/json
post
POST /facility/v1/bulk/_create HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 763

{
  "RequestInfo": {
    "apiId": "text",
    "ver": "text",
    "ts": 1,
    "action": "text",
    "did": "text",
    "key": "text",
    "msgId": "text",
    "requesterId": "text",
    "authToken": "text"
  },
  "Facilities": [
    {
      "tenantId": "tenantA",
      "isPermanent": true,
      "name": "Facility XYZ",
      "usage": "STORAGE_WAREHOUSE",
      "storageCapacity": 1,
      "address": {
        "tenantId": "tenantA",
        "doorNo": "text",
        "latitude": 1,
        "longitude": 1,
        "locationAccuracy": 1,
        "type": [
          "PERMANENT"
        ],
        "addressLine1": "text",
        "addressLine2": "text",
        "landmark": "text",
        "city": "text",
        "pincode": "text",
        "buildingName": "text",
        "street": "text",
        "locality": {
          "code": "text",
          "name": "text",
          "label": "text",
          "latitude": "text",
          "longitude": "text",
          "children": [
            "[Circular Reference]"
          ]
        }
      },
      "additionalFields": {
        "schema": "HOUSEHOLD",
        "version": 2,
        "fields": [
          {
            "key": "height",
            "value": 180
          }
        ]
      },
      "rowVersion": 1
    }
  ]
}
{
  "ResponseInfo": {
    "apiId": "text",
    "ver": "text",
    "ts": 1,
    "resMsgId": "text",
    "msgId": "text",
    "status": "SUCCESSFUL"
  }
}

Update the details of a existing facility

post

Update the details of a existing facility

Body
Responses
202
Facility request accepted.
application/json
post
POST /facility/v1/_update HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 852

{
  "RequestInfo": {
    "apiId": "text",
    "ver": "text",
    "ts": 1,
    "action": "text",
    "did": "text",
    "key": "text",
    "msgId": "text",
    "requesterId": "text",
    "authToken": "text"
  },
  "Facility": {
    "tenantId": "tenantA",
    "isPermanent": true,
    "name": "Facility XYZ",
    "usage": "STORAGE_WAREHOUSE",
    "storageCapacity": 1,
    "address": {
      "tenantId": "tenantA",
      "doorNo": "text",
      "latitude": 1,
      "longitude": 1,
      "locationAccuracy": 1,
      "type": [
        "PERMANENT"
      ],
      "addressLine1": "text",
      "addressLine2": "text",
      "landmark": "text",
      "city": "text",
      "pincode": "text",
      "buildingName": "text",
      "street": "text",
      "locality": {
        "code": "text",
        "name": "text",
        "label": "text",
        "latitude": "text",
        "longitude": "text",
        "children": [
          {
            "code": "text",
            "name": "text",
            "label": "text",
            "latitude": "text",
            "longitude": "text",
            "children": "[Circular Reference]"
          }
        ]
      }
    },
    "additionalFields": {
      "schema": "HOUSEHOLD",
      "version": 2,
      "fields": [
        {
          "key": "height",
          "value": 180
        }
      ]
    },
    "rowVersion": 1
  }
}
{
  "ResponseInfo": {
    "apiId": "text",
    "ver": "text",
    "ts": 1,
    "resMsgId": "text",
    "msgId": "text",
    "status": "SUCCESSFUL"
  },
  "Facility": {
    "id": "text",
    "tenantId": "tenantA",
    "isPermanent": true,
    "name": "Facility XYZ",
    "usage": "STORAGE_WAREHOUSE",
    "storageCapacity": 1,
    "address": {
      "id": "text",
      "tenantId": "tenantA",
      "doorNo": "text",
      "latitude": 1,
      "longitude": 1,
      "locationAccuracy": 1,
      "type": [
        "PERMANENT"
      ],
      "addressLine1": "text",
      "addressLine2": "text",
      "landmark": "text",
      "city": "text",
      "pincode": "text",
      "buildingName": "text",
      "street": "text",
      "locality": {
        "code": "text",
        "name": "text",
        "label": "text",
        "latitude": "text",
        "longitude": "text",
        "children": [
          {
            "code": "text",
            "name": "text",
            "label": "text",
            "latitude": "text",
            "longitude": "text",
            "children": "[Circular Reference]",
            "materializedPath": "text"
          }
        ],
        "materializedPath": "text"
      }
    },
    "additionalFields": {
      "schema": "HOUSEHOLD",
      "version": 2,
      "fields": [
        {
          "key": "height",
          "value": 180
        }
      ]
    },
    "isDeleted": true,
    "rowVersion": 1,
    "auditDetails": {
      "createdBy": "text",
      "lastModifiedBy": "text",
      "createdTime": 1,
      "lastModifiedTime": 1
    }
  }
}

Update the details of existing facilities in bulk

post

Update the details of a existing facilities in bulk

Body
Responses
202
Facility request accepted.
application/json
post
POST /facility/v1/bulk/_update HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 763

{
  "RequestInfo": {
    "apiId": "text",
    "ver": "text",
    "ts": 1,
    "action": "text",
    "did": "text",
    "key": "text",
    "msgId": "text",
    "requesterId": "text",
    "authToken": "text"
  },
  "Facilities": [
    {
      "tenantId": "tenantA",
      "isPermanent": true,
      "name": "Facility XYZ",
      "usage": "STORAGE_WAREHOUSE",
      "storageCapacity": 1,
      "address": {
        "tenantId": "tenantA",
        "doorNo": "text",
        "latitude": 1,
        "longitude": 1,
        "locationAccuracy": 1,
        "type": [
          "PERMANENT"
        ],
        "addressLine1": "text",
        "addressLine2": "text",
        "landmark": "text",
        "city": "text",
        "pincode": "text",
        "buildingName": "text",
        "street": "text",
        "locality": {
          "code": "text",
          "name": "text",
          "label": "text",
          "latitude": "text",
          "longitude": "text",
          "children": [
            "[Circular Reference]"
          ]
        }
      },
      "additionalFields": {
        "schema": "HOUSEHOLD",
        "version": 2,
        "fields": [
          {
            "key": "height",
            "value": 180
          }
        ]
      },
      "rowVersion": 1
    }
  ]
}
{
  "ResponseInfo": {
    "apiId": "text",
    "ver": "text",
    "ts": 1,
    "resMsgId": "text",
    "msgId": "text",
    "status": "SUCCESSFUL"
  }
}

Soft delete details of an existing facility

post

Soft delete details of an existing facility

Body
Responses
202
Facility request accepted.
application/json
post
POST /facility/v1/_delete HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 852

{
  "RequestInfo": {
    "apiId": "text",
    "ver": "text",
    "ts": 1,
    "action": "text",
    "did": "text",
    "key": "text",
    "msgId": "text",
    "requesterId": "text",
    "authToken": "text"
  },
  "Facility": {
    "tenantId": "tenantA",
    "isPermanent": true,
    "name": "Facility XYZ",
    "usage": "STORAGE_WAREHOUSE",
    "storageCapacity": 1,
    "address": {
      "tenantId": "tenantA",
      "doorNo": "text",
      "latitude": 1,
      "longitude": 1,
      "locationAccuracy": 1,
      "type": [
        "PERMANENT"
      ],
      "addressLine1": "text",
      "addressLine2": "text",
      "landmark": "text",
      "city": "text",
      "pincode": "text",
      "buildingName": "text",
      "street": "text",
      "locality": {
        "code": "text",
        "name": "text",
        "label": "text",
        "latitude": "text",
        "longitude": "text",
        "children": [
          {
            "code": "text",
            "name": "text",
            "label": "text",
            "latitude": "text",
            "longitude": "text",
            "children": "[Circular Reference]"
          }
        ]
      }
    },
    "additionalFields": {
      "schema": "HOUSEHOLD",
      "version": 2,
      "fields": [
        {
          "key": "height",
          "value": 180
        }
      ]
    },
    "rowVersion": 1
  }
}
{
  "ResponseInfo": {
    "apiId": "text",
    "ver": "text",
    "ts": 1,
    "resMsgId": "text",
    "msgId": "text",
    "status": "SUCCESSFUL"
  },
  "Facility": {
    "id": "text",
    "tenantId": "tenantA",
    "isPermanent": true,
    "name": "Facility XYZ",
    "usage": "STORAGE_WAREHOUSE",
    "storageCapacity": 1,
    "address": {
      "id": "text",
      "tenantId": "tenantA",
      "doorNo": "text",
      "latitude": 1,
      "longitude": 1,
      "locationAccuracy": 1,
      "type": [
        "PERMANENT"
      ],
      "addressLine1": "text",
      "addressLine2": "text",
      "landmark": "text",
      "city": "text",
      "pincode": "text",
      "buildingName": "text",
      "street": "text",
      "locality": {
        "code": "text",
        "name": "text",
        "label": "text",
        "latitude": "text",
        "longitude": "text",
        "children": [
          {
            "code": "text",
            "name": "text",
            "label": "text",
            "latitude": "text",
            "longitude": "text",
            "children": "[Circular Reference]",
            "materializedPath": "text"
          }
        ],
        "materializedPath": "text"
      }
    },
    "additionalFields": {
      "schema": "HOUSEHOLD",
      "version": 2,
      "fields": [
        {
          "key": "height",
          "value": 180
        }
      ]
    },
    "isDeleted": true,
    "rowVersion": 1,
    "auditDetails": {
      "createdBy": "text",
      "lastModifiedBy": "text",
      "createdTime": 1,
      "lastModifiedTime": 1
    }
  }
}

Soft delete details of existing facilities in bulk

post

Soft delete details of an existing facilities in bulk

Body
Responses
202
Facility request accepted.
application/json
post
POST /facility/v1/bulk/_delete HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 763

{
  "RequestInfo": {
    "apiId": "text",
    "ver": "text",
    "ts": 1,
    "action": "text",
    "did": "text",
    "key": "text",
    "msgId": "text",
    "requesterId": "text",
    "authToken": "text"
  },
  "Facilities": [
    {
      "tenantId": "tenantA",
      "isPermanent": true,
      "name": "Facility XYZ",
      "usage": "STORAGE_WAREHOUSE",
      "storageCapacity": 1,
      "address": {
        "tenantId": "tenantA",
        "doorNo": "text",
        "latitude": 1,
        "longitude": 1,
        "locationAccuracy": 1,
        "type": [
          "PERMANENT"
        ],
        "addressLine1": "text",
        "addressLine2": "text",
        "landmark": "text",
        "city": "text",
        "pincode": "text",
        "buildingName": "text",
        "street": "text",
        "locality": {
          "code": "text",
          "name": "text",
          "label": "text",
          "latitude": "text",
          "longitude": "text",
          "children": [
            "[Circular Reference]"
          ]
        }
      },
      "additionalFields": {
        "schema": "HOUSEHOLD",
        "version": 2,
        "fields": [
          {
            "key": "height",
            "value": 180
          }
        ]
      },
      "rowVersion": 1
    }
  ]
}
{
  "ResponseInfo": {
    "apiId": "text",
    "ver": "text",
    "ts": 1,
    "resMsgId": "text",
    "msgId": "text",
    "status": "SUCCESSFUL"
  }
}

Search existing facility

post

Search existing facility

Query parameters
limitanyRequired

Pagination - limit records in response

offsetanyRequired

Pagination - offset from which records should be returned in response

tenantIdanyRequired

Unique id for a tenant.

lastChangedSinceanyOptional

epoch of the time since when the changes on the object should be picked up. Search results from this parameter should include both newly created objects since this time as well as any modified objects since this time. This criterion is included to help polling clients to get the changes in system since a last time they synchronized with the platform.

includeDeletedanyOptional

Used in search APIs to specify if (soft) deleted records should be included in search results.

Body
Responses
200
Facilities.
application/json
post
POST /facility/v1/_search?limit=null&offset=null&tenantId=null HTTP/1.1
Host: 
Content-Type: application/json
Accept: */*
Content-Length: 252

{
  "RequestInfo": {
    "apiId": "text",
    "ver": "text",
    "ts": 1,
    "action": "text",
    "did": "text",
    "key": "text",
    "msgId": "text",
    "requesterId": "text",
    "authToken": "text"
  },
  "Facility": {
    "id": [
      "text"
    ],
    "isPermanent": true,
    "usage": "text",
    "storageCapacity": 1,
    "boundaryCode": "text"
  }
}
{
  "ResponseInfo": {
    "apiId": "text",
    "ver": "text",
    "ts": 1,
    "resMsgId": "text",
    "msgId": "text",
    "status": "SUCCESSFUL"
  },
  "Facilities": [
    {
      "id": "text",
      "tenantId": "tenantA",
      "isPermanent": true,
      "name": "Facility XYZ",
      "usage": "STORAGE_WAREHOUSE",
      "storageCapacity": 1,
      "address": {
        "id": "text",
        "tenantId": "tenantA",
        "doorNo": "text",
        "latitude": 1,
        "longitude": 1,
        "locationAccuracy": 1,
        "type": [
          "PERMANENT"
        ],
        "addressLine1": "text",
        "addressLine2": "text",
        "landmark": "text",
        "city": "text",
        "pincode": "text",
        "buildingName": "text",
        "street": "text",
        "locality": {
          "code": "text",
          "name": "text",
          "label": "text",
          "latitude": "text",
          "longitude": "text",
          "children": [
            "[Circular Reference]"
          ],
          "materializedPath": "text"
        }
      },
      "additionalFields": {
        "schema": "HOUSEHOLD",
        "version": 2,
        "fields": [
          {
            "key": "height",
            "value": 180
          }
        ]
      },
      "isDeleted": true,
      "rowVersion": 1,
      "auditDetails": {
        "createdBy": "text",
        "lastModifiedBy": "text",
        "createdTime": 1,
        "lastModifiedTime": 1
      }
    }
  ]
}

Last updated

Was this helpful?