Skip to content

Catalog · Party

8 operations in the catalog.party namespace.

Create a trading partner

POST /rpc/v1/catalog.party.createPartner

Requires permission catalog.party.write and the core module on the organization’s plan.

Field Type Required Description
name string yes
code string yes
types supplier | importer | exporter | cooperative | producer | mill | broker | warehouse | customer[] yes
country string no
defaultCurrency string no
paymentTermsDays integer no
contactEmail string no
contactPhone string no
website string no
notes string no
Terminal window
curl -X POST https://api.roastery.run/rpc/v1/catalog.party.createPartner \
-H "Authorization: Bearer $ROASTERY_API_KEY" \
-H "X-Roastery-Org: $ORG_ID" \
-H "Content-Type: application/json" \
-d '{}'

Create a producer

POST /rpc/v1/catalog.party.createProducer

Requires permission catalog.party.write and the core module on the organization’s plan.

Field Type Required Description
name string yes
code string yes
kind farm | cooperative | washing_station | estate | smallholder_group yes
partnerId string no
country string no
region string no
subregion string no
altitudeMinM integer no
altitudeMaxM integer no
latitude number no
longitude number no
varieties string[] no
processMethods string[] no
farmSizeHa number no
Terminal window
curl -X POST https://api.roastery.run/rpc/v1/catalog.party.createProducer \
-H "Authorization: Bearer $ROASTERY_API_KEY" \
-H "X-Roastery-Org: $ORG_ID" \
-H "Content-Type: application/json" \
-d '{}'

Get one trading partner

POST /rpc/v1/catalog.party.getPartner

Also available as GET with a URL-encoded input query parameter, so the response can be HTTP-cached.

Requires permission catalog.party.read and the core module on the organization’s plan.

Field Type Required Description
id string yes
Terminal window
curl -X POST https://api.roastery.run/rpc/v1/catalog.party.getPartner \
-H "Authorization: Bearer $ROASTERY_API_KEY" \
-H "X-Roastery-Org: $ORG_ID" \
-H "Content-Type: application/json" \
-d '{}'

Get one producer

POST /rpc/v1/catalog.party.getProducer

Also available as GET with a URL-encoded input query parameter, so the response can be HTTP-cached.

Requires permission catalog.party.read and the core module on the organization’s plan.

Field Type Required Description
id string yes
Terminal window
curl -X POST https://api.roastery.run/rpc/v1/catalog.party.getProducer \
-H "Authorization: Bearer $ROASTERY_API_KEY" \
-H "X-Roastery-Org: $ORG_ID" \
-H "Content-Type: application/json" \
-d '{}'

List trading partners

POST /rpc/v1/catalog.party.listPartners

Also available as GET with a URL-encoded input query parameter, so the response can be HTTP-cached.

Suppliers, importers, exporters, cooperatives and customers. A partner may be several of these at once, so types is a list.

Requires permission catalog.party.read and the core module on the organization’s plan.

Field Type Required Description
filter object no
page object no
Terminal window
curl -X POST https://api.roastery.run/rpc/v1/catalog.party.listPartners \
-H "Authorization: Bearer $ROASTERY_API_KEY" \
-H "X-Roastery-Org: $ORG_ID" \
-H "Content-Type: application/json" \
-d '{}'

List producers

POST /rpc/v1/catalog.party.listProducers

Also available as GET with a URL-encoded input query parameter, so the response can be HTTP-cached.

Farms, cooperatives and washing stations. Distinct from a partner because traceability follows where coffee was grown, not who sold it — the same farm’s coffee can arrive through different importers in different years.

Requires permission catalog.party.read and the core module on the organization’s plan.

Field Type Required Description
filter object no
page object no
Terminal window
curl -X POST https://api.roastery.run/rpc/v1/catalog.party.listProducers \
-H "Authorization: Bearer $ROASTERY_API_KEY" \
-H "X-Roastery-Org: $ORG_ID" \
-H "Content-Type: application/json" \
-d '{}'

Update a trading partner

POST /rpc/v1/catalog.party.updatePartner

Requires permission catalog.party.write and the core module on the organization’s plan.

Field Type Required Description
name string no
types supplier | importer | exporter | cooperative | producer | mill | broker | warehouse | customer[] no
country string no
defaultCurrency string no
paymentTermsDays integer no
contactEmail string no
contactPhone string no
website string no
notes string no
id string yes
isActive boolean no
Terminal window
curl -X POST https://api.roastery.run/rpc/v1/catalog.party.updatePartner \
-H "Authorization: Bearer $ROASTERY_API_KEY" \
-H "X-Roastery-Org: $ORG_ID" \
-H "Content-Type: application/json" \
-d '{}'

Update a producer

POST /rpc/v1/catalog.party.updateProducer

Requires permission catalog.party.write and the core module on the organization’s plan.

Field Type Required Description
name string no
kind farm | cooperative | washing_station | estate | smallholder_group no
partnerId string no
country string no
region string no
subregion string no
altitudeMinM integer no
altitudeMaxM integer no
latitude number no
longitude number no
varieties string[] no
processMethods string[] no
farmSizeHa number no
id string yes
isActive boolean no
Terminal window
curl -X POST https://api.roastery.run/rpc/v1/catalog.party.updateProducer \
-H "Authorization: Bearer $ROASTERY_API_KEY" \
-H "X-Roastery-Org: $ORG_ID" \
-H "Content-Type: application/json" \
-d '{}'