Search prices
Returns prices whose description matches the supplied search term.
Search results are not intended for read-after-write flows. Use List Prices when you need to retrieve a newly created or updated price immediately.
Related guide: Products and Prices
Query Parameters
- Type: stringsearchmin length:1required
Search term matched against price descriptions.
- Type: integerlimitmin:1max:100
Integer numbers.
- Type: stringlast
_key Opaque cursor for pagination. Use the
last_keyvalue from the previous response to retrieve the next page. - Type: stringproduct
Filter prices by Product ID.
- Type: stringenumintervalvaluesdailyweeklymonthlyquarterlyyearly
- Type: stringcurrency
- Type: integerFormat: int64min
_unit _amount min:0Signed 64-bit integers (long type).
- Type: integerFormat: int64max
_unit _amount min:0Signed 64-bit integers (long type).
- Type: booleanactive
- Type: stringFormat: date-timestart
_date the date-time notation as defined by RFC 3339, section 5.6, for example, 2017-07-21T17:32:28Z
- Type: stringFormat: date-timeend
_date the date-time notation as defined by RFC 3339, section 5.6, for example, 2017-07-21T17:32:28Z
- Type: "created" or "updated" or "unit_amount"enumsort
_by - Type: "asc" or "desc"enumsort
_order
Responses
- application/json
- application/json
- application/json
- application/json
- application/json
Request Example for get/v1/prices/search
curl 'https://api.paypercut.io/v1/prices/search?search=&limit=20&last_key=eyJsYXN0SWQiOiIyMTIxMDAyMWMyODU1MDA3ZWZhMmQ2NTcwMTgiLCJsYXN0Q3JlYXRlZEF0IjoiMjAyNC0wMS0xNVQxMDozMDowMFoifQ%3D%3D&sort_by=created&sort_order=desc' \
--header 'Authorization: Bearer YOUR_SECRET_TOKEN'
{
"items": [
{
"active": true,
"billing_scheme": "per_unit",
"created": 1,
"currency": "string",
"livemode": true,
"lookup_key": null,
"product": "01K755J9SV2364REVHB915Z2FW",
"product_data": {
"active": true,
"name": "string",
"description": "string",
"unit_label": "string",
"id": "string"
},
"recurring": {
"interval": "daily",
"interval_count": 1,
"meter": null,
"usage_type": "licensed"
},
"type": "one_time",
"unit_amount": null,
"unit_amount_decimal": null,
"id": "string"
}
],
"last_key": null
}
