prototypes
The prototypes query allows you to (not surprisingly!) return the Prototypes configured on the platform.
2 minute read
Key Information
Use-Case
Prototypes are a concept within the Marketplacer categorization domain. They allow you to define and associate sets Option Types (attributes) to a given part of your categorization tree. One possible use-case for using the prototypes
query is when you are wanting to sync taxonomies between systems (e.g. in this case Marketplacer would be the source system).
Further Points of Note
- Currently not available to Sellers, however Sellers can use the
node
ornodes
queries to return specificprototypes
Availability
- Operator API: Yes
- Seller API: No
Example
query getOptionTypesForPrototype{
prototypes(first: 100 after: null) {
nodes {
id
name
optionTypes {
nodes {
id
}
}
}
pageInfo {
hasNextPage
endCursor
}
}
}
Arguments
Name | Type | Description |
---|---|---|
ids | [ID] | Return prototypes based on their Ids |
after | String | Pagination cursor for moving through result set - more on pagination here |
before | String | Not in use - backwards pagination not supported |
first | Int | Pagination page size - more on pagination here |
last | Int | Not in use - backwards pagination not supported |
Response
Returns PrototypesConnection
Error Responses
HTTP Error | Error Message | Meaning |
---|---|---|
401 | Unauthorized | You don’t have access to the endpoint, likely Basic Authentication credentials are missing |
401 | API Token has expired | You don’t have access to the endpoint, likely that you are either not supplying an API Key, or the key you are supplying is invalid |
200 | Field ‘prototypes’ doesn’t exist on type ‘Query’ | Most likely returned if a Seller is attempting to use this query, or you are not supplying a valid API key |
Further Reading
- Connected Integration Blueprint
- How to update products
- This discussed the concepts on prototypes and taxonomy thoroughly