Catalog · Product
4 operations in the catalog.product namespace.
catalog.product.createProduct
Section titled “catalog.product.createProduct”Create a product
POST /rpc/v1/catalog.product.createProductRequires permission catalog.product.write and the core module on the organization’s plan.
Request
Section titled “Request”| Field | Type | Required | Description |
|---|---|---|---|
sku |
string | yes | |
name |
string | yes | |
format |
whole_bean | ground_espresso | ground_filter | ground_french_press | capsule | instant | drip_bag | bulk |
yes | |
netWeightKg |
number | no | |
listPrice |
number | no | |
currency |
string | no | |
barcode |
string | no |
Example
Section titled “Example”curl -X POST https://api.roastery.run/rpc/v1/catalog.product.createProduct \ -H "Authorization: Bearer $ROASTERY_API_KEY" \ -H "X-Roastery-Org: $ORG_ID" \ -H "Content-Type: application/json" \ -d '{}'catalog.product.getProduct
Section titled “catalog.product.getProduct”Get one product
POST /rpc/v1/catalog.product.getProductAlso available as GET with a URL-encoded input query parameter, so the response can be HTTP-cached.
Requires permission catalog.product.read and the core module on the organization’s plan.
Request
Section titled “Request”| Field | Type | Required | Description |
|---|---|---|---|
id |
string | yes |
Example
Section titled “Example”curl -X POST https://api.roastery.run/rpc/v1/catalog.product.getProduct \ -H "Authorization: Bearer $ROASTERY_API_KEY" \ -H "X-Roastery-Org: $ORG_ID" \ -H "Content-Type: application/json" \ -d '{}'catalog.product.listProducts
Section titled “catalog.product.listProducts”List products
POST /rpc/v1/catalog.product.listProductsAlso available as GET with a URL-encoded input query parameter, so the response can be HTTP-cached.
Requires permission catalog.product.read and the core module on the organization’s plan.
Request
Section titled “Request”| Field | Type | Required | Description |
|---|---|---|---|
filter |
object | no | |
page |
object | no |
Example
Section titled “Example”curl -X POST https://api.roastery.run/rpc/v1/catalog.product.listProducts \ -H "Authorization: Bearer $ROASTERY_API_KEY" \ -H "X-Roastery-Org: $ORG_ID" \ -H "Content-Type: application/json" \ -d '{}'catalog.product.updateProduct
Section titled “catalog.product.updateProduct”Update a product
POST /rpc/v1/catalog.product.updateProductRequires permission catalog.product.write and the core module on the organization’s plan.
Request
Section titled “Request”| Field | Type | Required | Description |
|---|---|---|---|
name |
string | no | |
format |
whole_bean | ground_espresso | ground_filter | ground_french_press | capsule | instant | drip_bag | bulk |
no | |
netWeightKg |
number | no | |
listPrice |
number | no | |
currency |
string | no | |
barcode |
string | no | |
id |
string | yes | |
isActive |
boolean | no |
Example
Section titled “Example”curl -X POST https://api.roastery.run/rpc/v1/catalog.product.updateProduct \ -H "Authorization: Bearer $ROASTERY_API_KEY" \ -H "X-Roastery-Org: $ORG_ID" \ -H "Content-Type: application/json" \ -d '{}'