Gets a list of all modifiers
GEThttps://euwest.api.elasticpath.com/pcm/pricebooks/:pricebookID/modifiers
Retrieves a list of price modifiers for the specified price book.
Filtering
Filtering is supported on this endpoint. For the general syntax, see Filtering.
You can filter on the following attributes and operators.
Operator | Attribute | Description | Example |
---|---|---|---|
eq | external_ref , name | Checks if the values you provide matches a price modifier. | filter=eq(name,largesupplement) |
Request
Path Parameters
Unique identifier of a Price Book
Query Parameters
This endpoint supports filtering. See Filtering.
Possible values: >= 1
The maximum number of records per page for this response. You can set this value up to 100. If no page size is set, the the page length store setting is used.
Possible values: <= 10000
The current offset by number of records, not pages. Offset is zero-based. The maximum records you can offset is 10,000. If no page offset is set, the page length store setting is used.
Responses
- 200
- default
The price modifier list.
- application/json
- Schema
- Example (auto)
Schema
meta object
data object[]required
links object
{
"meta": {
"results": {
"total": 1
},
"page": {
"limit": 10,
"offset": 0,
"current": 0,
"total": 1
}
},
"data": [
{
"type": "price-modifier",
"pricebook_external_ref": "a-pricebook-external-ref",
"attributes": {
"external_ref": "external-ref",
"currencies": {
"USD": {
"amount": 100,
"includes_tax": false,
"tiers": {
"min_5": {
"minimum_quantity": 5,
"amount": 50
}
}
},
"CAD": {
"amount": 127,
"includes_tax": false,
"tiers": {
"min_10": {
"minimum_quantity": 10,
"amount": 100
}
}
},
"GBP": {
"amount": 73,
"includes_tax": true,
"tiers": {
"min_20": {
"minimum_quantity": 20,
"amount": 60
}
}
}
},
"name": "large-supplement",
"modifier_type": "price_equals",
"created_at": "2020-09-22T09:00:00Z",
"updated_at": "2020-09-22T09:00:00Z"
},
"id": "37f2eed6-0bea-4d0b-a3c6-24cc76143bfd",
"meta": {
"owner": "store"
}
}
],
"links": {
"self": "/pcm/pricebooks/4c45e4ec-26e0-4043-86e4-c15b9cf985a7/modifiers",
"first": "/pcm/pricebooks/4c45e4ec-26e0-4043-86e4-c15b9cf985a7/modifiers?page[offset]=0&page[limit]=25",
"last": "/pcm/pricebooks/4c45e4ec-26e0-4043-86e4-c15b9cf985a7/modifiers?page[offset]=0&page[limit]=25",
"prev": "/pcm/pricebooks/4c45e4ec-26e0-4043-86e4-c15b9cf985a7/modifiers?page[offset]=0&page[limit]=25",
"next": "/pcm/pricebooks/4c45e4ec-26e0-4043-86e4-c15b9cf985a7/modifiers?page[offset]=25&page[limit]=25"
}
}
Unexpected error
- application/json
- Schema
- Example (auto)
Schema
errors object[]
{
"errors": [
{
"detail": "The modifier already exists",
"status": "409",
"title": "conflict"
}
]
}
Authorization: Authorization
name: Authorizationtype: httpin: headerscheme: bearer
- csharp
- curl
- dart
- go
- http
- java
- javascript
- kotlin
- c
- nodejs
- objective-c
- ocaml
- php
- powershell
- python
- r
- ruby
- rust
- shell
- swift
- HTTPCLIENT
- RESTSHARP
var client = new HttpClient();
var request = new HttpRequestMessage(HttpMethod.Get, "https://euwest.api.elasticpath.com/pcm/pricebooks/:pricebookID/modifiers");
request.Headers.Add("Accept", "application/json");
request.Headers.Add("Authorization", "Bearer <Authorization>");
var response = await client.SendAsync(request);
response.EnsureSuccessStatusCode();
Console.WriteLine(await response.Content.ReadAsStringAsync());