Download OpenAPI specification:Download
The Open Food Trust API provides insights into the food and ag supply chain with an emphasis towards supporting initiatives around sustainability, reduction of food waste, and to enable track and trace of agricultural products in a reliable and secure manner.
Gets weather data at desired location and over time range
operation required | string Enum: "daily" "hourly" request parameters to specify time range and location |
Parameters for issuing the credential.
string or Array of strings | |
From | number |
To | number |
Latitude | number |
Longitude | number |
{- "Field": "all",
- "From": 1590517644,
- "To": 1622053644,
- "Latitude": 35.883543,
- "Longitude": -79.016313
}
[- {
- "IsForecast": true,
- "FetchTime": 0,
- "Timezone": "string",
- "Latitude": 0,
- "Longitude": 0,
- "Time": 0,
- "Summary": "string",
- "Icon": "string",
- "SunriseTime": 0,
- "SunsetTime": 0,
- "TemperatureHigh": 0,
- "TemperatureLow": 0,
- "Precipitation": 0,
- "PrecipProbability": 0,
- "Temperature": 0,
- "ApparentTemperature": 0,
- "DewPoint": 0,
- "Humidity": 0,
- "Pressure": 0,
- "WindSpeed": 0,
- "WindGust": 0,
- "WindBearing": 0,
- "CloudCover": 0,
- "UvIndex": 0,
- "Visibility": 0,
- "SoilTemp5cm": 0,
- "SoilMoisture10cm": 0
}
]
Gets the aggregate value(s) of a specified field at desired location and over time range
operation required | string Enum: "sum" "avg" "min" "max" "summary" "daily" "hourly" type of aggregation to perform |
Parameters for issuing the credential.
string or Array of strings | |
From | number |
To | number |
Latitude | number |
Longitude | number |
{- "Field": "all",
- "From": 1590517644,
- "To": 1622053644,
- "Latitude": 35.883543,
- "Longitude": -79.016313
}
{- "Field": "string",
- "Latitude": 0,
- "Longitude": 0,
- "Data": {
- "Date": 0,
- "Operation": "string",
- "Value": 0
}
}
Creates a new document with the specified properties and content (via file upload) and permissions information.
The request body must include valid MIME multipart/form-data
. While the properties piece is required, the content
and permissions
pieces are optional. By default permissions is set to private
so that only the document owners can access it.
properties | string |
content | string <binary> |
permissions | string |
{- "id": "doc123"
}
Retrieves data about the supplied array of documents such as their properties and attachments.
Use GET /documents/{docId}/content
to retrieve the contents of the documents.
docIds required | Array of strings Array of document IDs |
[- {
- "id": "string",
- "orgId": "string",
- "version": 1,
- "timestamp": "2019-09-12T03:04:23+00:00",
- "permissions": {
- "permissionsMode": "linked",
- "permittedOrgIds": [
- "string"
]
}, - "categories": [
- "string"
], - "properties": {
- "documentType": "Generic Document",
- "documentTitle": "CTR Report"
}, - "content": {
- "filename": "string",
- "contentType": "application/pdf"
}, - "attachments": {
- "property1": {
- "id": "string",
- "filename": "string",
- "contentType": "application/pdf"
}, - "property2": {
- "id": "string",
- "filename": "string",
- "contentType": "application/pdf"
}
}
}
]
Retrieves data about a specific document such as its properties and attachments.
Use GET /documents/{docId}/content
to retrieve the content of the document.
docId required | string Document ID |
version | integer <int32> Document version |
{- "id": "string",
- "orgId": "string",
- "version": 1,
- "timestamp": "2019-09-12T03:04:23+00:00",
- "permissions": {
- "permissionsMode": "linked",
- "permittedOrgIds": [
- "string"
]
}, - "categories": [
- "string"
], - "properties": {
- "documentType": "Generic Document",
- "documentTitle": "CTR Report"
}, - "content": {
- "filename": "string",
- "contentType": "application/pdf"
}, - "attachments": {
- "property1": {
- "id": "string",
- "filename": "string",
- "contentType": "application/pdf"
}, - "property2": {
- "id": "string",
- "filename": "string",
- "contentType": "application/pdf"
}
}
}
Updates a document's properties and, optionally, permissions and content. A successful update of a document will result in an increase in the version number
The request body's MIME type should be application/json
docId required | string Document ID |
properties | string |
content | string <binary> |
permissions | string |
{- "id": "doc123"
}
If the document has content, it will be retrieved.
docId required | string Document ID |
version | integer <int32> Document version |
{- "code": "genericError",
- "message": "An unexpected error has occurred"
}
Uploads a file to the document. A successful upload will result in the document version being increased.
docId required | string Document ID |
content | string <binary> |
{- "id": "doc123"
}
Updating the permissions will not change the version number of the document. Both permissionsMode
and permittedOrgIds
should be present to properly update the document
docId required | string Document ID |
Permissions information
permissionsMode | string (PermissionsMode) Enum: "linked" "private" Permissions mode |
permittedOrgIds | Array of strings Organization IDs permitted to access the document |
{- "permissionsMode": "linked",
- "permittedOrgIds": [
- "string"
]
}
{- "permissionsMode": "linked",
- "permittedOrgIds": [
- "string"
]
}
Searches across all documents using the provided parameters. The full properties and contents of the documents will not be used to reduce load. Other calls should be used to retrieve the full set of document information.
limit | number <double> Default: 500 Limits the total number of document summaries returned. Valid range is 0 thru 1000. |
offset | number <double> Default: 0 Start position for the next set of paginated document summaries. |
count | boolean Default: false Specifies whether to retrieve the total count of document summaries that match the search conditions. |
Must be valid JSON. Supported search conditions are TBD
orgId | string |
orgIdNot | string |
object (Timestamp) | |
categories | Array of strings |
object (Properties) |
{- "orgId": "org12345",
- "orgIdNot": "org12345",
- "timestamp": {
- "inRange": {
- "lower": "2019-10-01T00:00:00+00:00"
}
}, - "categories": [
- "string"
], - "properties": {
- "documentType": "GAA BAP Certificate",
- "documentTitle": "CTR Report 2006",
- "expiryDate": {
- "inRange": {
- "lower": "2019-10-01T00:00:00+00:00"
}
}, - "locationGLNList": [
- "string"
], - "epcList": [
- "string"
], - "productList": [
- "string"
], - "eventIDList": [
- "string"
], - "transactionIDList": [
- "string"
]
}
}
{- "count": 100,
- "documentSummaries": [
- {
- "id": "string",
- "orgId": "string",
- "version": 1,
- "timestamp": "string",
- "categories": [
- "string"
], - "properties": {
- "documentType": "string",
- "documentTitle": "string",
- "issueDate": "string",
- "expiryDate": "string",
- "locationGLNList": [
- "string"
], - "epcList": [
- "string"
], - "productList": [
- "string"
], - "eventIDList": [
- "string"
], - "transactionIDList": [
- "string"
]
}
}
]
}
Adds and uploads a new attachment to the document. A successful upload will result in the version number being increased.
docId required | string Document ID |
type | string |
content | string <binary> |
{- "id": "att123"
}
Retrieves a specific attachment from a specific document.
docId required | string Document ID |
attachmentId required | string attachment ID |
{- "code": "genericError",
- "message": "An unexpected error has occurred"
}
Updates a documents attachment. A successful upload will increase the document's version number
docId required | string Document ID |
attachmentId required | string attachment ID |
content | string <binary> |
{- "id": "att123"
}
Deletes a documents attechment. A successful deletion will result in the version number being increased.
docId required | string Document ID |
attachmentId required | string attachment ID |
{- "code": "genericError",
- "message": "An unexpected error has occurred"
}
Returns the status document trasnactions that may be in progress. These transactions are identified using correlation IDs that were returned when the transaction was begun.
correlationIds required | Array of strings Array of correlation IDs, obtained from previous create or update requests. |
[- {
- "correlationId": "cor12345",
- "transactionStatus": "success",
- "errorMessage": "string"
}
]
If document categories are desired, a map is returned of the specified categories
{- "Certificate": {
- "documentTypes": [
- {
- "documentType": "Generic Certificate"
}
]
}, - "Other": {
- "documentTypes": [
- {
- "documentType": "Generic Certificate"
}
]
}
}
Retrieves product information
entity_id[] | Array of strings <uuid> Array of entity IDs. |
description | string A general search string used to return matching product data. |
asset_id[] | Array of strings An array of asset IDs, such as lots and serials. |
product_id[] | Array of strings An array of product IDs. |
limit | number <double> Default: 500 A numerical limit to the number of records initially returned. Paging can then be used via the |
startPage | string Specifies the record number at which to start the page of results. The number of records returned will be based on the |
{- "products": [
- {
- "id": "urn:product:class:0048562.chicken",
- "entity_id": "string",
- "description": "Demo: fresh chicken",
- "object_sku": "03485JDSIJ"
}
],
}
Creates a new product
Request body with the parameters for product post.
entity_id | Array of strings <uuid> |
description | string |
asset_id | Array of strings |
product_id | Array of strings |
{- "entity_id": [
- "497f6eca-6276-4993-bfeb-53cbbbba6f08"
], - "description": "string",
- "asset_id": [
- "string"
], - "product_id": [
- "string"
]
}
{- "products": [
- {
- "id": "urn:product:class:0048562.chicken",
- "entity_id": "string",
- "description": "Demo: fresh chicken",
- "object_sku": "03485JDSIJ"
}
],
}
Updates an existing product
product_id required | any Product ID |
Request body with updates to the product entry.
entity_id | Array of strings <uuid> |
description | string |
asset_id | Array of strings |
{- "entity_id": [
- "497f6eca-6276-4993-bfeb-53cbbbba6f08"
], - "description": "string",
- "asset_id": [
- "string"
]
}
{- "products": [
- {
- "id": "urn:product:class:0048562.chicken",
- "entity_id": "string",
- "description": "Demo: fresh chicken",
- "object_sku": "03485JDSIJ"
}
],
}
Retrieves information on the facility location
entity_id[] | Array of strings <uuid> Array of entity IDs. |
location_id[] | Array of strings An array of location IDs. |
limit | number <double> Default: 500 A numerical limit to the number of records initially returned. Paging can then be used for further retrieval. Default limit 500. |
startPage | string Specifies the record number at which to start the page of results. The number of records returned will be based on the |
{- "locations": [
- {
- "id": "9876543example",
- "entity_id": "string",
- "location_type": "FARM",
- "location_name": "Bia Orchards",
- "street_address": "123 Jakers Street",
- "city": "Middlefield",
- "country_code": "US",
- "po_box_number": null,
- "postal_code": "06455",
- "state": "CT",
- "latitude": 0,
- "longitude": 0
}
],
}
Creates a new location entry.
Parameters of the location to post.
entity_id | string |
location_type | string |
street_address | string |
location_name | string |
city | string |
country_code | string |
po_box_number | string |
postal_code | string |
state | string |
latitude | number <double> |
longitude | number <double> |
{- "entity_id": "string",
- "location_type": "FARM",
- "location_name": "Bia Orchards",
- "street_address": "123 Jakers Street",
- "city": "Kimberton",
- "country_code": "US",
- "po_box_number": null,
- "postal_code": "19460",
- "state": "PA",
- "latitude": 0,
- "longitude": 0
}
{- "locations": [
- {
- "id": "9876543example",
- "entity_id": "string",
- "location_type": "FARM",
- "location_name": "Bia Orchards",
- "street_address": "123 Jakers Street",
- "city": "Middlefield",
- "country_code": "US",
- "po_box_number": null,
- "postal_code": "06455",
- "state": "CT",
- "latitude": 0,
- "longitude": 0
}
],
}
Updates an existing location
Parameters of the location to update.
id | string |
entity_id | string |
location_type | string |
street_address | string |
location_name | string |
city | string |
country_code | string |
po_box_number | string |
postal_code | string |
state | string |
latitude | number <double> |
longitude | number <double> |
{- "id": "9876543example",
- "entity_id": "string",
- "location_type": "FARM",
- "location_name": "Bia Orchards",
- "street_address": "123 Jakers Street",
- "city": "Kimberton",
- "country_code": "US",
- "po_box_number": null,
- "postal_code": "19460",
- "state": "PA",
- "latitude": 0,
- "longitude": 0
}
{- "locations": [
- {
- "id": "9876543example",
- "entity_id": "string",
- "location_type": "FARM",
- "location_name": "Bia Orchards",
- "street_address": "123 Jakers Street",
- "city": "Middlefield",
- "country_code": "US",
- "po_box_number": null,
- "postal_code": "06455",
- "state": "CT",
- "latitude": 0,
- "longitude": 0
}
],
}
Retrieves metadata related to items such as products, locations, etc.
metadata_id[] | Array of strings Array of IDs for metadata. |
product_id[] | Array of strings An array of product IDs. |
entity_id[] | Array of strings <uuid> Array of entity IDs. |
location_id[] | Array of strings An array of location IDs. |
event_id[] | Array of strings Array of event identifiers. |
metadata_start_timestamp | string Returns records with a payload timestamp on or after the timestamp provided |
metadata_end_timestamp | string Returns records with a payload timestamp strictly before the timestamp provided |
limit | number <double> Default: 500 A numerical limit to the number of records initially returned. Paging can then be used for further retrieval. Default limit 500. |
startPage | string Specifies the record number at which to start the page of results. The number of records returned will be based on the |
{- "metadata_id": "3jh43u2i5u3i4",
- "metadata_timestamp": "2019-03-13T14:52:48.350Z",
- "metadata_content_type": "shipping delay",
- "product_ids": [
- "42354754jk5k345"
], - "location_ids": [
- "923901832"
], - "customData": {
- "description": "Shipment was delayed for two days due to a weather system.",
- "spoilageRisk": "low"
}
}
Creates a new metadata entry.
Parameters of the metadata to post.
entity_id | string |
metadata_timestamp | string |
metadata_content_type | string |
event_ids | Array of strings |
asset_ids | Array of strings |
location_ids | Array of strings |
customData | object |
{- "metadata_timestamp": "2019-03-13T14:52:48.350Z",
- "metadata_content_type": "shipping delay",
- "product_ids": [
- "42354754jk5k345"
], - "location_ids": [
- "923901832"
], - "customData": {
- "description": "Shipment was delayed for two days due to a weather system.",
- "spoilageRisk": "high"
}
}
{- "metadata_id": "3jh43u2i5u3i4",
- "metadata_timestamp": "2019-03-13T14:52:48.350Z",
- "metadata_content_type": "shipping delay",
- "product_ids": [
- "42354754jk5k345"
], - "location_ids": [
- "923901832"
], - "customData": {
- "description": "Shipment was delayed for two days due to a weather system.",
- "spoilageRisk": "low"
}
}
Updates existing metadata entry
Parameters of the metadata to update.
metadata_id | string |
entity_id | string |
metadata_timestamp | string |
metadata_content_type | string |
event_ids | Array of strings |
asset_ids | Array of strings |
location_ids | Array of strings |
customData | object |
{- "metadata_id": "3jh43u2i5u3i4",
- "metadata_timestamp": "2019-03-13T14:52:48.350Z",
- "metadata_content_type": "shipping delay",
- "product_ids": [
- "42354754jk5k345"
], - "location_ids": [
- "923901832"
], - "customData": {
- "description": "Shipment was delayed for two days due to a weather system.",
- "spoilageRisk": "low"
}
}
{- "metadata_id": "3jh43u2i5u3i4",
- "metadata_timestamp": "2019-03-13T14:52:48.350Z",
- "metadata_content_type": "shipping delay",
- "product_ids": [
- "42354754jk5k345"
], - "location_ids": [
- "923901832"
], - "customData": {
- "description": "Shipment was delayed for two days due to a weather system.",
- "spoilageRisk": "low"
}
}
Retrieves details of events
entity_id[] | Array of strings <uuid> Array of entity IDs. |
asset_id[] | Array of strings Return records with the asset identifiers provided. |
location_id[] | Array of strings An array of location IDs. |
product_id[] | Array of strings An array of product IDs. |
event_type[] | Array of strings An array of event types. |
transaction_id[] | Array of strings An array of IDs for the business transaction. |
transaction_type[] | Array of strings Array transaction types to retrieve records. |
step[] | Array of strings Array of Business Step IDs |
event_start_timestamp | string Returns results based on events on or after the provided timestamp. |
event_end_timestamp | string Returns results based on events before the provided timestamp. |
limit | number <double> Default: 500 A numerical limit to the number of records initially returned. Paging can then be used for further retrieval. Default limit 500. |
startPage | string Specifies the record number at which to start the page of results. The number of records returned will be based on the |
{- "events": [
- {
- "id": "string",
- "entity_id": "string",
- "event_type": "aggregation",
- "event_time": "string",
- "transformation_id": "string",
- "biz_step": "string",
- "disposition": "string",
- "read_point_location_id": "string",
- "read_point_sub_location_id": "string",
- "biz_location_id": "string",
- "biz_sub_location_id": "string",
- "asset_ids": [
- "string"
], - "parent_asset_id": "string",
- "child_asset_ids": [
- "string"
], - "quantities": { }
}
],
}
Creates a new event entry.
Parameters of the event to post.
Array of objects (event) |
{- "entity_id": "12entity34",
- "event_type": "observation",
- "event_time": "2019-03-13T14:52:48.350Z",
- "transformation_id": "exampleIDforTransformation",
- "asset_ids": [
- "asset0",
- "asset1"
], - "parent_asset_id": "parentAssetIDExample",
- "quantities": {
- "asset_id": "assetIDexample",
- "quantity": 130,
- "uom": "uomExample"
}, - "source_location_ids": [
- "locationID1",
- "locationID2"
], - "destination_location_ids": [
- "destinationID1",
- "ldestinationID2"
], - "transaction_ids": [
- "transaction1",
- "transaction2"
]
}
{- "id": "string",
- "entity_id": "string",
- "event_type": "aggregation",
- "event_time": "string",
- "transformation_id": "string",
- "biz_step": "string",
- "disposition": "string",
- "read_point_location_id": "string",
- "read_point_sub_location_id": "string",
- "biz_location_id": "string",
- "biz_sub_location_id": "string",
- "asset_ids": [
- "string"
], - "parent_asset_id": "string",
- "child_asset_ids": [
- "string"
], - "quantities": { }
}
Updates existing event entry
Parameters of the event to update.
Array of objects (event) |
{- "event_id": "eventIDexample",
- "entity_id": "12entity34",
- "event_type": "observation",
- "event_time": "2019-03-13T14:52:48.350Z",
- "transformation_id": "exampleIDforTransformation",
- "asset_ids": [
- "asset0",
- "asset1"
], - "parent_asset_id": "parentAssetIDExample",
- "quantities": {
- "asset_id": "assetIDexample",
- "quantity": 130,
- "uom": "uomExample"
}, - "source_location_ids": [
- "locationID1",
- "locationID2"
], - "destination_location_ids": [
- "destinationID1",
- "ldestinationID2"
], - "transaction_ids": [
- "transaction1",
- "transaction2"
]
}
{- "id": "string",
- "entity_id": "string",
- "event_type": "aggregation",
- "event_time": "string",
- "transformation_id": "string",
- "biz_step": "string",
- "disposition": "string",
- "read_point_location_id": "string",
- "read_point_sub_location_id": "string",
- "biz_location_id": "string",
- "biz_sub_location_id": "string",
- "asset_ids": [
- "string"
], - "parent_asset_id": "string",
- "child_asset_ids": [
- "string"
], - "quantities": { }
}
Finds an asset of any type, whether it be a lot, serial, or EPC.
product_id[] | Array of strings An array of product IDs. |
asset_id[] | Array of strings An array of EPC, lot or serial IDs. |
asset_type | Array of strings An array of asset types. |
event_start_timestamp | string Returns results based on events on or after the provided timestamp. |
event_end_timestamp | string Returns results based on events before the provided timestamp. |
limit | number <double> Default: 500 A numerical limit to the number of records initially returned. Paging can then be used for further retrieval. Default limit 500. |
startPage | string Specifies the record number at which to start the page of results. The number of records returned will be based on the |
{- "assets": [
- {
- "id": "thisAssetID",
- "product_id": "productIDExample"
}
]
}
Creates a new asset entry.
Parameters of the asset to post.
id | string |
asset_type | string |
product_id | string |
{- "id": "thisAssetID",
- "asset_type": "pallet",
- "product_id": "productIDExample"
}
{- "id": "string",
- "entity_id": "string",
- "event_type": "aggregation",
- "event_time": "string",
- "transformation_id": "string",
- "biz_step": "string",
- "disposition": "string",
- "read_point_location_id": "string",
- "read_point_sub_location_id": "string",
- "biz_location_id": "string",
- "biz_sub_location_id": "string",
- "asset_ids": [
- "string"
], - "parent_asset_id": "string",
- "child_asset_ids": [
- "string"
], - "quantities": { }
}
Updates existing asset entry
Parameters of the event to update.
id | string |
asset_type | string |
product_id | string |
{- "id": "thisAssetID",
- "asset_type": "pallet",
- "product_id": "productIDExample"
}
{- "id": "string",
- "entity_id": "string",
- "event_type": "aggregation",
- "event_time": "string",
- "transformation_id": "string",
- "biz_step": "string",
- "disposition": "string",
- "read_point_location_id": "string",
- "read_point_sub_location_id": "string",
- "biz_location_id": "string",
- "biz_sub_location_id": "string",
- "asset_ids": [
- "string"
], - "parent_asset_id": "string",
- "child_asset_ids": [
- "string"
], - "quantities": { }
}
Retrieve a consumer trace for a specific lot, serial, or pallet
asset_id required | string EPC of lot, serial, pallet, or GRAI to trace |
product_id[] | Array of strings An array of product IDs. |
depth | integer <int32> [ 1 .. 10 ] Default: 5 Returns the number of steps to traverse in the trace. |
upstream | boolean Default: true Boolean value indicating whether or not to trace upstream. |
downstream | boolean Default: true Boolean value indicating whether or not to trace downstream. |
{- "trace": {
- "asset_id": "string",
- "events": [
- {
- "asset_id": "string"
}
], - "output_assets": [
- {
- "asset_id": "string",
- "events": [
- { }
], - "output_assets": [
- { }
], - "input_assets": [
- { }
], - "parent_assets": [
- { }
], - "child_assets": [
- { }
]
}
], - "input_assets": [
- {
- "asset_id": "string",
- "events": [
- { }
], - "output_assets": [
- { }
], - "input_assets": [
- { }
], - "parent_assets": [
- { }
], - "child_assets": [
- { }
]
}
], - "parent_assets": [
- {
- "asset_id": "string",
- "events": [
- { }
], - "output_assets": [
- { }
], - "input_assets": [
- { }
], - "parent_assets": [
- { }
], - "child_assets": [
- { }
]
}
], - "child_assets": [
- {
- "asset_id": "string",
- "events": [
- { }
], - "output_assets": [
- { }
], - "input_assets": [
- { }
], - "parent_assets": [
- { }
], - "child_assets": [
- { }
]
}
]
}
}
Retrieves imld data related to assets and products.
asset_id[] | Array of strings |
product_id[] | Array of strings |
best_before_date_start_timestamp | string |
best_before_date_end_timestamp | string |
first_freeze_date_start_timestamp | string |
first_freeze_date_end_timestamp | string |
harvest_start_date_start_timestamp | string |
harvest_start_date_end_timestamp | string |
harvest_end_date_start_timestamp | string |
harvest_end_date_end_timestamp | string |
item_expiration_date_start_timestamp | string |
item_expiration_date_end_timestamp | string |
sell_by_date_start_timestamp | string |
sell_by_date_end_timestamp | string |
limit | number <double> Default: 500 |
start | string |
{- "ilmds": [
- {
- "asset_id": "string",
- "id": "string",
- "product_id": "string",
- "additional_trade_item_identification": "string",
- "additional_trade_item_identification_type": "string",
- "lot_number": "string",
- "functional_name": "string",
- "regulated_product_name": "string",
- "trade_item_description": "string",
- "strength_description": "string",
- "net_content_description": "string",
- "description_short": "string",
- "label_description": "string",
- "drained_weight": "string",
- "drained_weight_uom": "string",
- "gross_weight": "string",
- "gross_weight_uom": "string",
- "net_weight": "string",
- "net_weight_uom": "string",
- "manufacturer_of_trade_item_location_name": "string",
- "country_of_origin": "string",
- "sell_by_date": "string",
- "first_freeze_date": "string",
- "item_expiration_date": "string",
- "best_before_date": "string",
- "harvest_start_date": "string",
- "harvest_end_date": "string",
- "farm_list": [
- {
- "identification": "string",
- "identification_type": "string"
}
], - "growing_method_code": "string",
- "production_method_for_fish_and_seafood": "string",
- "unloading_port": "string",
- "vessel_list": [
- {
- "id": "string",
- "name": "string"
}
]
}
]
}
Creates new ilmd entry.
Object to submit post a new ilmds entry.
Array of objects (ilmd) |
{- "events": [
- {
- "asset_id": "string",
- "id": "string",
- "product_id": "string",
- "additional_trade_item_identification": "string",
- "additional_trade_item_identification_type": "string",
- "lot_number": "string",
- "functional_name": "string",
- "regulated_product_name": "string",
- "trade_item_description": "string",
- "strength_description": "string",
- "net_content_description": "string",
- "description_short": "string",
- "label_description": "string",
- "drained_weight": "string",
- "drained_weight_uom": "string",
- "gross_weight": "string",
- "gross_weight_uom": "string",
- "net_weight": "string",
- "net_weight_uom": "string",
- "manufacturer_of_trade_item_location_name": "string",
- "country_of_origin": "string",
- "sell_by_date": "string",
- "first_freeze_date": "string",
- "item_expiration_date": "string",
- "best_before_date": "string",
- "harvest_start_date": "string",
- "harvest_end_date": "string",
- "farm_list": [
- {
- "identification": "string",
- "identification_type": "string"
}
], - "growing_method_code": "string",
- "production_method_for_fish_and_seafood": "string",
- "unloading_port": "string",
- "vessel_list": [
- {
- "id": "string",
- "name": "string"
}
]
}
]
}
{- "ilmds": [
- {
- "asset_id": "string",
- "id": "string",
- "product_id": "string",
- "additional_trade_item_identification": "string",
- "additional_trade_item_identification_type": "string",
- "lot_number": "string",
- "functional_name": "string",
- "regulated_product_name": "string",
- "trade_item_description": "string",
- "strength_description": "string",
- "net_content_description": "string",
- "description_short": "string",
- "label_description": "string",
- "drained_weight": "string",
- "drained_weight_uom": "string",
- "gross_weight": "string",
- "gross_weight_uom": "string",
- "net_weight": "string",
- "net_weight_uom": "string",
- "manufacturer_of_trade_item_location_name": "string",
- "country_of_origin": "string",
- "sell_by_date": "string",
- "first_freeze_date": "string",
- "item_expiration_date": "string",
- "best_before_date": "string",
- "harvest_start_date": "string",
- "harvest_end_date": "string",
- "farm_list": [
- {
- "identification": "string",
- "identification_type": "string"
}
], - "growing_method_code": "string",
- "production_method_for_fish_and_seafood": "string",
- "unloading_port": "string",
- "vessel_list": [
- {
- "id": "string",
- "name": "string"
}
]
}
]
}
Updates existing ilmds entry
Parameters of the ilmds record to update.
Array of objects (ilmd) |
{- "events": [
- {
- "asset_id": "string",
- "id": "string",
- "product_id": "string",
- "additional_trade_item_identification": "string",
- "additional_trade_item_identification_type": "string",
- "lot_number": "string",
- "functional_name": "string",
- "regulated_product_name": "string",
- "trade_item_description": "string",
- "strength_description": "string",
- "net_content_description": "string",
- "description_short": "string",
- "label_description": "string",
- "drained_weight": "string",
- "drained_weight_uom": "string",
- "gross_weight": "string",
- "gross_weight_uom": "string",
- "net_weight": "string",
- "net_weight_uom": "string",
- "manufacturer_of_trade_item_location_name": "string",
- "country_of_origin": "string",
- "sell_by_date": "string",
- "first_freeze_date": "string",
- "item_expiration_date": "string",
- "best_before_date": "string",
- "harvest_start_date": "string",
- "harvest_end_date": "string",
- "farm_list": [
- {
- "identification": "string",
- "identification_type": "string"
}
], - "growing_method_code": "string",
- "production_method_for_fish_and_seafood": "string",
- "unloading_port": "string",
- "vessel_list": [
- {
- "id": "string",
- "name": "string"
}
]
}
]
}
{- "ilmds": [
- {
- "asset_id": "string",
- "id": "string",
- "product_id": "string",
- "additional_trade_item_identification": "string",
- "additional_trade_item_identification_type": "string",
- "lot_number": "string",
- "functional_name": "string",
- "regulated_product_name": "string",
- "trade_item_description": "string",
- "strength_description": "string",
- "net_content_description": "string",
- "description_short": "string",
- "label_description": "string",
- "drained_weight": "string",
- "drained_weight_uom": "string",
- "gross_weight": "string",
- "gross_weight_uom": "string",
- "net_weight": "string",
- "net_weight_uom": "string",
- "manufacturer_of_trade_item_location_name": "string",
- "country_of_origin": "string",
- "sell_by_date": "string",
- "first_freeze_date": "string",
- "item_expiration_date": "string",
- "best_before_date": "string",
- "harvest_start_date": "string",
- "harvest_end_date": "string",
- "farm_list": [
- {
- "identification": "string",
- "identification_type": "string"
}
], - "growing_method_code": "string",
- "production_method_for_fish_and_seafood": "string",
- "unloading_port": "string",
- "vessel_list": [
- {
- "id": "string",
- "name": "string"
}
]
}
]
}
Retrieves information for entities.
entity_id[] | Array of strings <uuid> Array of entity IDs. |
entity_name[] | Array of strings An array of entity names. |
company_prefix[] | Array of strings An array of company prefixes. |
asset_id[] | Array of strings Array of EPC or relevant product identifiers. |
product_id[] | Array of strings An array of product IDs. |
location_id[] | Array of strings An array of location IDs to use in returning records. |
limit | number <double> Default: 500 A numerical limit to the number of records initially returned. Paging can then be used for further retrieval. Default limit 500. |
startPage | string Specifies the record number at which to start the page of results. The number of records returned will be based on the |
{- "entities": [
- {
- "id": "string",
- "name": "string",
- "company_prefix": [
- "string"
], - "asset_id": [
- "string"
], - "product_id": [
- "string"
], - "location_id": [
- "string"
]
}
]
}
Creates new entity entry.
Object to post a new entity entry.
Array of objects (entity) |
{- "name": "CJ Berries",
- "company_prefix": "CJB",
- "asset_id": "assetIDexample",
- "product_id": "prodIDexample",
- "location_id": "locationIDexample"
}
{- "entities": [
- {
- "id": "string",
- "name": "string",
- "company_prefix": [
- "string"
], - "asset_id": [
- "string"
], - "product_id": [
- "string"
], - "location_id": [
- "string"
]
}
]
}
Updates existing entity entry
Parameters of the entity record to update.
Array of objects (entity) |
{- "id": "entityIDexample",
- "name": "CJ Berries",
- "company_prefix": "CJB",
- "asset_id": "assetIDexample",
- "product_id": "prodIDexample",
- "location_id": "locationIDexample"
}
{- "id": "string",
- "name": "string",
- "company_prefix": [
- "string"
], - "asset_id": [
- "string"
], - "product_id": [
- "string"
], - "location_id": [
- "string"
]
}
Returns assets used as source materials for other assets. For example, avocados used to make guacamole.
asset_id[] required | Array of strings Returns records with the asset identifiers (URN) provided. |
{- "asset_ids": [
- {
- "asset_id": "string",
- "hash": "string"
}
], - "sources": [
- {
- "hash": "string",
- "source": "string"
}
]
}
Creates new source entry.
Object to post a new source entry.
Array of objects (sources) |
{- "asset_ids": [
- "GuacamoleIDexample"
], - "sources": [
- "avacadoIDexample",
- "cilantroIDexample"
]
}
{- "asset_ids": [
- {
- "asset_id": "string",
- "hash": "string"
}
], - "sources": [
- {
- "hash": "string",
- "source": "string"
}
]
}
Updates existing sources entry
Parameters of the source record to update.
Array of objects (sources) |
{- "asset_ids": [
- "Guacamole"
], - "sources": [
- "avacadoIDexample",
- "cilantroIDexample"
]
}
{- "asset_ids": [
- {
- "asset_id": "string",
- "hash": "string"
}
], - "sources": [
- {
- "hash": "string",
- "source": "string"
}
]
}
Issues a credential and returns it in the response body.
Parameters for issuing the credential.
object (Credential) A JSON-LD Verifiable Credential without a proof. | |
object (IssueCredentialOptions) Options for specifying how the LinkedDataProof is created. |
{- "credential": {
- "type": [
- "VerifiableCredential",
- "UniversityDegreeCredential"
], - "issuer": "did:example:123",
- "issuanceDate": "2020-03-16T22:37:26.544Z",
- "credentialSubject": {
- "id": "did:example:123",
- "degree": {
- "type": "BachelorDegree",
- "name": "Bachelor of Science and Arts"
}
}
}, - "options": {
- "verificationMethod": "did:example:123#z6MksHh7qHWvybLg5QTPPdG2DgEjjduBDArV9EF9mRiRzMBN",
- "proofPurpose": "assertionMethod",
- "created": "2020-04-02T18:48:36Z",
- "domain": "revocation.example",
- "challenge": "d436f0c8-fbd9-4e48-bbb2-55fc5d0920a8",
- "credentialStatus": {
- "type": "RevocationList2020Status"
}
}
}
{- "type": [
- "VerifiableCredential",
- "UniversityDegreeCredential"
], - "issuer": "did:example:123",
- "issuanceDate": "2020-03-16T22:37:26.544Z",
- "credentialSubject": {
- "id": "did:example:123",
- "degree": {
- "type": "BachelorDegree",
- "name": "Bachelor of Science and Arts"
}
}, - "proof": {
- "type": "Ed25519Signature2018",
- "created": "2020-04-02T18:28:08Z",
- "verificationMethod": "did:example:123#z6MksHh7qHWvybLg5QTPPdG2DgEjjduBDArV9EF9mRiRzMBN",
- "proofPurpose": "assertionMethod",
- "jws": "eyJhbGciOiJFZERTQSIsImI2NCI6ZmFsc2UsImNyaXQiOlsiYjY0Il19..YtqjEYnFENT7fNW-COD0HAACxeuQxPKAmp4nIl8jYAu__6IH2FpSxv81w-l5PvE1og50tS9tH8WyXMlXyo45CA"
}
}
Updates the status of an issued credential.
Parameters for updating the status of the issued credential.
credentialId | string |
type | string |
status | number |
{- "credentialId": "urn:uuid:45a44711-e457-4fa8-9b89-69fe0287c86a",
- "type": "RevocationList2020Status",
- "status": 0
}
Verifies a verifiableCredential and returns a verificationResult in the response body.
Parameters for verifying a verifiableCredential.
object (VerifiableCredential) A JSON-LD Verifiable Credential with a proof. | |
object (VerifyOptions) Options for specifying how the LinkedDataProof is created. |
{- "verifiableCredential": {
- "type": [
- "VerifiableCredential",
- "UniversityDegreeCredential"
], - "issuer": "did:example:123",
- "issuanceDate": "2020-03-16T22:37:26.544Z",
- "credentialSubject": {
- "id": "did:example:123",
- "degree": {
- "type": "BachelorDegree",
- "name": "Bachelor of Science and Arts"
}
}, - "proof": {
- "type": "Ed25519Signature2018",
- "created": "2020-04-02T18:28:08Z",
- "verificationMethod": "did:example:123#z6MksHh7qHWvybLg5QTPPdG2DgEjjduBDArV9EF9mRiRzMBN",
- "proofPurpose": "assertionMethod",
- "jws": "eyJhbGciOiJFZERTQSIsImI2NCI6ZmFsc2UsImNyaXQiOlsiYjY0Il19..YtqjEYnFENT7fNW-COD0HAACxeuQxPKAmp4nIl8jYAu__6IH2FpSxv81w-l5PvE1og50tS9tH8WyXMlXyo45CA"
}
}, - "options": {
- "verificationMethod": "did:example:123#z6MksHh7qHWvybLg5QTPPdG2DgEjjduBDArV9EF9mRiRzMBN",
- "proofPurpose": "assertionMethod",
- "created": "2020-04-02T18:48:36Z",
- "domain": "example.com",
- "challenge": "d436f0c8-fbd9-4e48-bbb2-55fc5d0920a8"
}
}
{- "checks": [
- "proof"
], - "warnings": [ ],
- "errors": [ ]
}
Verifies a verifiablePresentation and returns a verificationResult in the response body. Given the possibility of denial of service, buffer overflow, or other style attacks, an implementation is permitted to rate limit or restrict requests against this API endpoint to those requests that contain only a single credential with a 413 or 429 error code as appropriate.
Parameters for verifying a verifiablePresentation.
object (VerifiablePresentation) A JSON-LD Verifiable Presentation with a proof. | |
object (VerifyOptions) Options for specifying how the LinkedDataProof is created. |
{- "verifiablePresentation": {
- "holder": "did:example:123",
- "type": "VerifiablePresentation",
- "verifiableCredential": [
- {
}, - {
- "type": [
- "VerifiableCredential",
- "UniversityDegreeCredential"
]
}, - {
- "issuer": "did:example:123"
}, - {
- "issuanceDate": "2020-03-16T22:37:26.544Z"
}, - {
- "credentialSubject": {
- "id": "did:example:123",
- "degree": {
- "type": "BachelorDegree",
- "name": "Bachelor of Science and Arts"
}
}
}, - {
- "proof": {
- "type": "Ed25519Signature2018",
- "created": "2020-04-02T18:28:08Z",
- "verificationMethod": "did:example:123#z6MksHh7qHWvybLg5QTPPdG2DgEjjduBDArV9EF9mRiRzMBN",
- "proofPurpose": "assertionMethod",
- "jws": "eyJhbGciOiJFZERTQSIsImI2NCI6ZmFsc2UsImNyaXQiOlsiYjY0Il19..YtqjEYnFENT7fNW-COD0HAACxeuQxPKAmp4nIl8jYAu__6IH2FpSxv81w-l5PvE1og50tS9tH8WyXMlXyo45CA"
}
}
], - "proof": {
- "type": "Ed25519Signature2018",
- "created": "2020-04-02T18:28:08Z",
- "verificationMethod": "did:example:123#z6MksHh7qHWvybLg5QTPPdG2DgEjjduBDArV9EF9mRiRzMBN",
- "proofPurpose": "assertionMethod",
- "jws": "eyJhbGciOiJFZERTQSIsImI2NCI6ZmFsc2UsImNyaXQiOlsiYjY0Il19..YtqjEYnFENT7fNW-COD0HAACxeuQxPKAmp4nIl8jYAu__6IH2FpSxv81w-l5PvE1og50tS9tH8WyXMlXyo45CA"
}
}, - "options": {
- "verificationMethod": "did:example:123#z6MksHh7qHWvybLg5QTPPdG2DgEjjduBDArV9EF9mRiRzMBN",
- "proofPurpose": "assertionMethod",
- "created": "2020-04-02T18:48:36Z",
- "domain": "example.com",
- "challenge": "d436f0c8-fbd9-4e48-bbb2-55fc5d0920a8"
}
}
{- "checks": [
- "proof"
], - "warnings": [ ],
- "errors": [ ]
}
Proves a presentation and returns it in the response body.
Parameters for proving the presentation.
object (Presentation) A JSON-LD Verifiable Presentation without a proof. | |
object (PresentCredentialOptions) Options for specifying how the LinkedDataProof is created. |
{- "presentation": {
- "holder": "did:example:123",
- "type": "VerifiablePresentation",
- "verifiableCredential": [
- {
}, - {
- "type": [
- "VerifiableCredential",
- "UniversityDegreeCredential"
]
}, - {
- "issuer": "did:example:123"
}, - {
- "issuanceDate": "2020-03-16T22:37:26.544Z"
}, - {
- "credentialSubject": {
- "id": "did:example:123",
- "degree": {
- "type": "BachelorDegree",
- "name": "Bachelor of Science and Arts"
}
}
}, - {
- "proof": {
- "type": "Ed25519Signature2018",
- "created": "2020-04-02T18:28:08Z",
- "verificationMethod": "did:example:123#z6MksHh7qHWvybLg5QTPPdG2DgEjjduBDArV9EF9mRiRzMBN",
- "proofPurpose": "assertionMethod",
- "jws": "eyJhbGciOiJFZERTQSIsImI2NCI6ZmFsc2UsImNyaXQiOlsiYjY0Il19..YtqjEYnFENT7fNW-COD0HAACxeuQxPKAmp4nIl8jYAu__6IH2FpSxv81w-l5PvE1og50tS9tH8WyXMlXyo45CA"
}
}
]
}, - "options": {
- "verificationMethod": "did:example:123#z6MksHh7qHWvybLg5QTPPdG2DgEjjduBDArV9EF9mRiRzMBN",
- "proofPurpose": "assertionMethod",
- "created": "2020-04-02T18:48:36Z",
- "domain": "example.com",
- "challenge": "d436f0c8-fbd9-4e48-bbb2-55fc5d0920a8"
}
}
{- "holder": "did:example:123",
- "type": "VerifiablePresentation",
- "verifiableCredential": [
- {
}, - {
- "type": [
- "VerifiableCredential",
- "UniversityDegreeCredential"
]
}, - {
- "issuer": "did:example:123"
}, - {
- "issuanceDate": "2020-03-16T22:37:26.544Z"
}, - {
- "credentialSubject": {
- "id": "did:example:123",
- "degree": {
- "type": "BachelorDegree",
- "name": "Bachelor of Science and Arts"
}
}
}, - {
- "proof": {
- "type": "Ed25519Signature2018",
- "created": "2020-04-02T18:28:08Z",
- "verificationMethod": "did:example:123#z6MksHh7qHWvybLg5QTPPdG2DgEjjduBDArV9EF9mRiRzMBN",
- "proofPurpose": "assertionMethod",
- "jws": "eyJhbGciOiJFZERTQSIsImI2NCI6ZmFsc2UsImNyaXQiOlsiYjY0Il19..YtqjEYnFENT7fNW-COD0HAACxeuQxPKAmp4nIl8jYAu__6IH2FpSxv81w-l5PvE1og50tS9tH8WyXMlXyo45CA"
}
}
], - "proof": {
- "type": "Ed25519Signature2018",
- "created": "2020-04-02T18:28:08Z",
- "verificationMethod": "did:example:123#z6MksHh7qHWvybLg5QTPPdG2DgEjjduBDArV9EF9mRiRzMBN",
- "proofPurpose": "assertionMethod",
- "jws": "eyJhbGciOiJFZERTQSIsImI2NCI6ZmFsc2UsImNyaXQiOlsiYjY0Il19..YtqjEYnFENT7fNW-COD0HAACxeuQxPKAmp4nIl8jYAu__6IH2FpSxv81w-l5PvE1og50tS9tH8WyXMlXyo45CA"
}
}