### Get Product Source: https://developer.erudus.com/api-reference/products Retrieves the complete data set for a specific product using its ID. ```APIDOC ## GET /products/{product_id} ### Description Retrieves the complete data set for a specific product. Use this endpoint after identifying a product of interest using the List Products endpoint. ### Method GET ### Endpoint /products/{product_id} ### Parameters #### Path Parameters - **product_id** (string) - Required - The unique identifier of the product to retrieve. ### Request Example ``` GET /products/prod_123 ``` ### Response #### Success Response (200) - **data** (object) - The complete data set for the product. - **product_id** (string) - The unique identifier for the product. - **name** (string) - The name of the product. - **description** (string) - A detailed description of the product. - **attributes** (object) - A collection of product-specific attributes (e.g., allergens, nutrients). #### Response Example ```json { "data": { "product_id": "prod_123", "name": "Example Product", "description": "This is a detailed description of the example product.", "attributes": { "allergens": [ "milk", "soy" ], "nutrients": { "calories": 100, "protein": 10 } } } } ``` ``` -------------------------------- ### Get Catalog Product PDF - OpenAPI Specification Source: https://developer.erudus.com/api-reference/wholesaler-catalogs This OpenAPI 3.0.3 specification details the 'Get Catalog Product PDF' endpoint. It includes information on the request method (GET), path parameters, response types (including error handling for 401 Unauthorized), and associated tags. ```json { "openapi": "3.0.3", "info": { "title": "Erudus API", "version": "2.0.0" }, "tags": [ { "name": "Wholesaler Catalogs", "description": "\nAccess and manage Wholesaler Product Catalogs.\n\nA Wholesaler Catalog contains products listed by the Wholesaler's own internal product codes.\n\nThese can be attached to specific versions of products and so can therefore be different to the version of the product held as the latest version in the main data pool.\n\nAn API key associated with the relevant wholesaler account is required." } ], "servers": [ { "url": "https://api.erudus.com" } ], "security": [ { "default": [] } ], "components": { "securitySchemes": { "default": { "type": "http", "scheme": "bearer", "description": "You can retrieve your token by visiting your dashboard and clicking Manage API tokens." } } }, "paths": { "/v2/catalogs/{wholesaler}/pdf/{code}": { "get": { "summary": "Get Catalog Product PDF", "operationId": "getCatalogProductPDF", "description": "Download Catalog Product PDF.\n\nThis will return the Erudus PDF specification of the specific version of the product to which the product code is attached in the Wholesaler's catalog.", "parameters": [], "responses": { "401": { "description": "", "content": { "application/json": { "schema": { "type": "object", "properties": { "message": { "type": "string" } } } } } } }, "tags": [ "Wholesaler Catalogs" ] } } } } ``` -------------------------------- ### Get Product PDF Source: https://developer.erudus.com/api-reference/products Downloads the product PDF specification for a given product. This endpoint allows you to retrieve the Erudus PDF product specification. ```APIDOC ## GET /v2/products/{product}/pdf ### Description Download Product PDF. This will return the Erudus PDF product specification. ### Method GET ### Endpoint /v2/products/{product}/pdf ### Parameters #### Path Parameters - **product** (string) - Required - The identifier for the product. #### Query Parameters - **version** (string) - Optional - Get a specific version of the product. ### Request Example ```json { "example": "request body" } ``` ### Response #### Success Response (200) - **data** (object) - Contains the product PDF specification. #### Response Example ```json { "example": "response body" } ``` #### Error Response (401) - **message** (string) - Description of the error. ``` -------------------------------- ### Get Product Source: https://developer.erudus.com/api-reference/products Retrieve data for a single product using the unique Erudus ID reference. This endpoint allows fetching specific product details, including general information, outer packaging details, inner pack information, and safety data. ```APIDOC ## GET /v2/products/{product} ### Description Retrieve data for a single product using the unique Erudus ID reference. ### Method GET ### Endpoint /v2/products/{product} ### Parameters #### Path Parameters - **product** (string) - Required - The unique Erudus ID reference for the product. #### Query Parameters - **version** (string) - Optional - Get a specific version of the product. - **output** (string) - Optional - Sets an alternative output format to raw, flat or ungroup. ### Request Example ```json { "example": "request body" } ``` ### Response #### Success Response (200) - **data** (object) - Contains the product data. - **erudus_id** (string) - The unique Erudus ID. - **standardised_name** (string) - The standardized name of the product. - **status** (string) - The status of the product data. - **version** (string) - The version of the product data. - **changed_at** (string) - The timestamp when the product data was last changed. - **latest_version** (string) - Indicates if this is the latest version. - **change_reason** (string) - The reason for the last change. - **change_type** (integer) - The type of change. - **reviewed_at** (string) - The timestamp when the product data was last reviewed. - **parent_id** (string) - The ID of the parent product, if applicable. - **replaced_by** (array) - List of product IDs that have replaced this one. - **codes** (array) - List of product codes. - **general** (object) - General information about the product. - **manufacturer_product_name** (string) - The manufacturer's name for the product. - **product_name** (string) - The name of the product. - **manufacturer** (integer) - The ID of the manufacturer. - **manufacturer_name** (string) - The name of the manufacturer. - **label** (integer) - The ID of the label. - **label_name** (string) - The name of the label. - **label_code** (string) - The code of the label. - **brand** (integer) - The ID of the brand. - **brand_name** (string) - The name of the brand. - **schema** (string) - The schema identifier for the product. - **schema_name** (string) - The name of the product schema. - **manufacturer_product_code** (string) - The manufacturer's product code. - **product_description** (string) - A description of the product. - **product_type** (object) - Information about the product type. - **id** (integer) - The ID of the product type. - **description** (string) - The description of the product type. - **product_category** (object) - Information about the product category. - **id** (integer) - The ID of the product category. - **description** (string) - The description of the product category. - **storage_type** (object) - Information about the product's storage type. - **id** (integer) - The ID of the storage type. - **description** (string) - The description of the storage type. - **manufacturer_address** (string) - The address of the manufacturer. - **marketing_description** (string) - The marketing description of the product. - **day_code** (string) - The day code for the product. - **batch_code** (string) - The batch code for the product. - **manufacturer_version_number** (string) - The manufacturer's version number. - **effective_date** (string) - The effective date of the product information. - **outer** (object) - Information about the outer packaging. - **no_outer_present** (string) - Indicates if outer packaging is present. - **traded_unit_gtin** (string) - The GTIN of the traded unit (outer packaging). - **variable_inner_components** (string) - Indicates if the inner components are variable. - **consumer_units_per_traded** (object) - Number of consumer units per traded unit. - **value** (integer) - The value. - **units** (string) - The units. - **outer_case_gross_weight** (object) - The gross weight of the outer case. - **value** (number) - The value. - **units** (string) - The units. - **outer_case_height** (object) - The height of the outer case. - **value** (integer) - The value. - **units** (string) - The units. - **outer_case_depth** (object) - The depth of the outer case. - **value** (integer) - The value. - **units** (string) - The units. - **outer_case_net_weight** (object) - The net weight of the outer case. - **value** (number) - The value. - **units** (string) - The units. - **outer_case_width** (object) - The width of the outer case. - **value** (integer) - The value. - **units** (string) - The units. - **trade_item_splittable** (object) - Indicates if the trade item is splittable. - **value** (integer) - The value. - **description** (string) - The description. - **value_added_tax_rate** (string) - The value-added tax rate. - **inner_packs_in_case** (string) - The number of inner packs in the case. - **inner_pack** (object) - Information about the inner packaging. - **inner_pack_height** (string) - The height of the inner pack. - **inner_pack_depth** (string) - The depth of the inner pack. - **inner_pack_width** (string) - The width of the inner pack. - **inner_pack_gtin** (string) - The GTIN of the inner pack. - **inner_pack_splittable** (string) - Indicates if the inner pack is splittable. - **inner_pack_gross_weight** (string) - The gross weight of the inner pack. - **inner_pack_net_weight** (string) - The net weight of the inner pack. - **inner_components_in_pack** (string) - The number of inner components in the pack. - **inner_pack_product_code** (string) - The product code for the inner pack. - **safety_outer** (object) - Safety information related to the outer packaging. - **product_health_warning** (string) - Health warnings for the product. - **age_restriction** (string) - Age restrictions for the product. #### Response Example ```json { "data": { "erudus_id": "12345", "standardised_name": "Example Product", "status": "active", "version": "1.0", "changed_at": "2023-10-27T10:00:00Z", "latest_version": "true", "change_reason": "Initial release", "change_type": 1, "reviewed_at": "2023-10-27T10:00:00Z", "parent_id": null, "replaced_by": [], "codes": [ { "type": "GTIN", "code": "01234567890123" } ], "general": { "manufacturer_product_name": "Example Product Name", "product_name": "Example Product", "manufacturer": 1, "manufacturer_name": "Example Manufacturer", "label": 1, "label_name": "Example Label", "label_code": "ELC123", "brand": 1, "brand_name": "Example Brand", "schema": "product_schema_v1", "schema_name": "Product Schema v1", "manufacturer_product_code": "EMP123", "product_description": "This is an example product.", "product_type": { "id": 1, "description": "Food" }, "product_category": { "id": 1, "description": "Snack" }, "storage_type": { "id": 1, "description": "Ambient" }, "manufacturer_address": "123 Manufacturer St, City, Country", "marketing_description": "A delicious example product.", "day_code": "123", "batch_code": "ABC123XYZ", "manufacturer_version_number": "v1.0", "effective_date": "2023-10-27" }, "outer": { "no_outer_present": "false", "traded_unit_gtin": "09876543210987", "variable_inner_components": "false", "consumer_units_per_traded": { "value": 12, "units": "units" }, "outer_case_gross_weight": { "value": 5.5, "units": "kg" }, "outer_case_height": { "value": 20, "units": "cm" }, "outer_case_depth": { "value": 30, "units": "cm" }, "outer_case_net_weight": { "value": 5.0, "units": "kg" }, "outer_case_width": { "value": 40, "units": "cm" }, "trade_item_splittable": { "value": 0, "description": "Not splittable" }, "value_added_tax_rate": "20%", "inner_packs_in_case": "12" }, "inner_pack": { "inner_pack_height": "5", "inner_pack_depth": "10", "inner_pack_width": "10", "inner_pack_gtin": "11223344556677", "inner_pack_splittable": "false", "inner_pack_gross_weight": "0.45", "inner_pack_net_weight": "0.40", "inner_components_in_pack": "1", "inner_pack_product_code": "EIPC123" }, "safety_outer": { "product_health_warning": "May contain nuts.", "age_restriction": "18+" } } } ``` ``` -------------------------------- ### Product Handling Instructions Schema Definition Source: https://developer.erudus.com/api-reference/wholesaler-catalogs Defines the structure for product handling and storage instructions, including directions for use, general storage guidelines, post-opening storage, and shelf life after defrosting. All fields are strings, allowing for free-text descriptions. ```json { "handling": { "type": "object", "properties": { "directions_for_use": {"type": "string"}, "storage_instructions": {"type": "string"}, "storage_instructions_after_opening": {"type": "string"}, "shelf_life_once_defrosted": {"type": "string"} } } } ``` -------------------------------- ### Get Label Source: https://developer.erudus.com/api-reference/labels Retrieves the details for a specific label. ```APIDOC ## GET /v2/labels/{label} ### Description Get a Label details. ### Method GET ### Endpoint /v2/labels/{label} #### Path Parameters - **label** (string) - Required - The identifier of the label to retrieve. ### Response #### Success Response (200) - **(response body structure not defined in provided OpenAPI spec)** #### Error Response (401) - **message** (string) - Description of the error, typically indicating unauthorized access. ``` -------------------------------- ### List Products Endpoint - OpenAPI Specification Source: https://developer.erudus.com/api-reference/products This snippet details the OpenAPI 3.0.3 specification for the 'List Products' GET endpoint. It outlines the available query parameters for filtering, sorting, and pagination, as well as the structure of the JSON response, including product details and pagination information. ```json { "openapi": "3.0.3", "info": { "title": "Erudus API", "version": "2.0.0" }, "tags": [ { "name": "Products", "description": "\nAPIs for getting product data held in the Erudus data pool.\n\nTypical usage involves calling the List Products endpoint to find products of interest and those that have recently been updated. The Get Product end point can then be called to obtain the complete data set for a product.\n\nProduct data is returned in JSON format inside the data element. A full product specification includes data structured inside several sub-sections and one or more inner components. The data values are collected together in related sections, for example \"allergens\" or \"nutrients\".\n\nSee endpoint sections below for example data responses.\n\nEach product complies to a specification type schema. Each product can therefore\ncontain different sets of attributes depending on its type and whether data has been\nprovided by the manufacturer of the product." } ], "servers": [ { "url": "https://api.erudus.com" } ], "security": [ { "default": [] } ], "components": { "securitySchemes": { "default": { "type": "http", "scheme": "bearer", "description": "You can retrieve your token by visiting your dashboard and clicking Manage API tokens." } } }, "paths": { "/v2/products": { "get": { "summary": "List Products", "operationId": "listProducts", "description": "Get a paginated list of products. Use next in response to get cursor value for next page.", "parameters": [ { "in": "query", "name": "sort", "description": "Sort results by changed_at, manufacturer_product_name. Prefixing with a hyphen will reverse order. Defaults to '-changed_at'.", "required": false, "schema": { "type": "string", "description": "Sort results by changed_at, manufacturer_product_name. Prefixing with a hyphen will reverse order. Defaults to '-changed_at'." } }, { "in": "query", "name": "filter[manufacturer]", "description": "Filter by ID of manufacturer.", "required": false, "schema": { "type": "integer", "description": "Filter by ID of manufacturer." } }, { "in": "query", "name": "filter[brand]", "description": "Filter by ID of brand.", "required": false, "schema": { "type": "integer", "description": "Filter by ID of brand." } }, { "in": "query", "name": "filter[label]", "description": "Filter by ID of label.", "required": false, "schema": { "type": "integer", "description": "Filter by ID of label." } }, { "in": "query", "name": "filter[manufacturer_product_code]", "description": "Filter by manufacturer product code.", "required": false, "schema": { "type": "string", "description": "Filter by manufacturer product code." } }, { "in": "query", "name": "filter[changed_at]", "description": "Filter by date product changed equal to (eq:), greater than (gt:) or less than a date (lt:).", "required": false, "schema": { "type": "string", "description": "Filter by date product changed equal to (eq:), greater than (gt:) or less than a date (lt:)." } }, { "in": "query", "name": "filter[status]", "description": "Filter by product's current status, i.e. published or archived. Defaults to 'published,archived'.", "required": false, "schema": { "type": "string", "description": "Filter by product's current status, i.e. published or archived. Defaults to 'published,archived'." } }, { "in": "query", "name": "cursor", "description": "Cursor hash value for next page.", "required": false, "schema": { "type": "string", "description": "Cursor hash value for next page." } }, { "in": "query", "name": "limit", "description": "Number of records per page.", "required": false, "schema": { "type": "integer", "description": "Number of records per page." } }, { "in": "query", "name": "count", "description": "Flag to request return of count value for query.", "required": false, "schema": { "type": "integer", "description": "Flag to request return of count value for query." } } ], "responses": { "200": { "description": "", "content": { "application/json": { "schema": { "oneOf": [ { "description": "", "type": "object", "properties": { "next": { "type": "string" }, "previous": { "type": "string" }, "data": { "type": "array", "items": { "type": "object", "properties": { "erudus_id": { "type": "string" }, "status": { "type": "string" }, "version": { "type": "string" }, "changed_at": { "type": "string" }, "latest_version": { "type": "string" }, "latest_at": { "type": "string" }, "schema": { "type": "string" }, "schema_name": { "type": "string" }, "manufacturer_product_name": { "type": "string" }, "product_name": { "type": "string" }, "standardised_name": { "type": "string" }, "manufacturer_product_code": { "type": "string" }, "traded_unit_gtin": { "type": "string" }, "manufacturer_version_number": { "type": "string" }, "manufacturer": { "type": "integer" }, "manufacturer_name": { "type": "string" }, "brand": { "type": "integer" }, "brand_name": { "type": "string" }, "label": { "type": "integer" }, "label_name": { "type": "string" }, "label_code": { "type": "string" }, "components": { "type": "array", "items": { "type": "object", "properties": { "component_uuid": { "type": "string" }, "component_name": { "type": "string" }, "internal_gtin": { "type": "string" }, "manufacturers_component_code": { "type": "string" } } } }, "parent_id": { "type": "string" }, "change_typ": { "type": "string" } } } } } } ] } } } } } } } } } ``` -------------------------------- ### Product Handling Instructions Structure Source: https://developer.erudus.com/api-reference/products Defines the structure for product handling instructions, including directives. This section is currently minimal and may be expanded. ```json { "direc": {"type": "object", "properties": {}} } ``` -------------------------------- ### List Products Source: https://developer.erudus.com/api-reference/products Retrieves a list of products, often used to find products of interest or those recently updated. ```APIDOC ## GET /products ### Description Retrieves a list of products. This is typically the first step to discover products or identify recently updated ones. ### Method GET ### Endpoint /products ### Parameters #### Query Parameters - **updated_since** (string) - Optional - Filter products updated after a specific date. ### Request Example ``` GET /products?updated_since=2023-01-01 ``` ### Response #### Success Response (200) - **data** (array) - An array of product objects. - **product_id** (string) - The unique identifier for the product. - **name** (string) - The name of the product. - **updated_at** (string) - The timestamp when the product was last updated. #### Response Example ```json { "data": [ { "product_id": "prod_123", "name": "Example Product", "updated_at": "2023-10-27T10:00:00Z" } ] } ``` ``` -------------------------------- ### Get Catalog Product PDF Source: https://developer.erudus.com/api-reference/wholesaler-catalogs Download the Erudus PDF specification for a specific product version within a Wholesaler's catalog using its product code. ```APIDOC ## GET /v2/catalogs/{wholesaler}/pdf/{code} ### Description Download Catalog Product PDF. This will return the Erudus PDF specification of the specific version of the product to which the product code is attached in the Wholesaler's catalog. ### Method GET ### Endpoint /v2/catalogs/{wholesaler}/pdf/{code} ### Parameters #### Path Parameters - **wholesaler** (string) - Required - The unique identifier for the wholesaler. - **code** (string) - Required - The product code used by the wholesaler. ### Request Example (No request body for GET requests) ### Response #### Success Response (200) - (Binary data representing the PDF file) #### Response Example (PDF file content) ``` -------------------------------- ### Get Product Feature Image Source: https://developer.erudus.com/api-reference/images Retrieves the primary feature image for a product, as designated by the Brand Owner. The response provides URLs for various image sizes. ```APIDOC ## GET /v2/images/{product}/feature ### Description Returns the feature image for the product. This is set by the Brand Owner. The response includes URLs of different size images if available from the system. ### Method GET ### Endpoint `/v2/images/{product}/feature` ### Parameters #### Path Parameters - **product** (string) - Required - The identifier of the product for which to retrieve the feature image. #### Query Parameters - **wholesaler** (integer) - Optional - Show images for a specific wholesaler (includes brand and wholesaler's images). ### Request Example ```json { "example": "GET /v2/images/12345/feature?wholesaler=67890" } ``` ### Response #### Success Response (200) - **data** (object) - An object containing the feature image details. - **id** (string) - The unique identifier for the image. - **owner_id** (integer) - The ID of the owner of the image. - **owner_type** (string) - The type of the owner (e.g., 'brand', 'wholesaler'). - **description** (string) - A description of the image. - **type** (object) - Information about the image type. - **id** (integer) - The ID of the image type. - **name** (string) - The name of the image type. - **description** (string) - A description of the image type. - **width** (integer) - The width of the image in pixels. - **height** (integer) - The height of the image in pixels. - **created_at** (string) - The timestamp when the image was created. - **updated_at** (string) - The timestamp when the image was last updated. - **status** (string) - The status of the image (e.g., 'active', 'inactive'). - **mime** (string) - The MIME type of the image file. - **url_original** (string) - The URL for the original image. - **url** (string) - The URL for a standard size image. - **url_medium** (string) - The URL for a medium size image. - **url_large** (string) - The URL for a large size image. #### Response Example ```json { "example": { "data": { "id": "img_xyz789", "owner_id": 101, "owner_type": "brand", "description": "Product feature image", "type": { "id": 1, "name": "Main", "description": "Primary product image" }, "width": 1200, "height": 900, "created_at": "2023-10-26T09:00:00Z", "updated_at": "2023-10-26T09:00:00Z", "status": "active", "mime": "image/png", "url_original": "https://cdn.erudus.com/images/original/img_xyz789.png", "url": "https://cdn.erudus.com/images/standard/img_xyz789.png", "url_medium": "https://cdn.erudus.com/images/medium/img_xyz789.png", "url_large": "https://cdn.erudus.com/images/large/img_xyz789.png" } } } ``` ``` -------------------------------- ### API Request Authentication Header Source: https://developer.erudus.com/getting-started/quickstart-1 This example demonstrates how to include an API Token in the Authorization header for authenticated API requests. The token should be prefixed with 'Bearer '. ```http Authorization: Bearer kYwxZ6LKTBrJXtHdThUnq9zKyHa1nteL9cOtsxL45591fd7d ```