Catalog · Party
8 operations in the catalog.party namespace.
catalog.party.createPartner
Section titled “catalog.party.createPartner”Create a trading partner
POST /rpc/v1/catalog.party.createPartnerRequires permission catalog.party.write and the core module on the organization’s plan.
Request
Section titled “Request”| 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 |
Example
Section titled “Example”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 '{}'catalog.party.createProducer
Section titled “catalog.party.createProducer”Create a producer
POST /rpc/v1/catalog.party.createProducerRequires permission catalog.party.write and the core module on the organization’s plan.
Request
Section titled “Request”| 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 |
Example
Section titled “Example”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 '{}'catalog.party.getPartner
Section titled “catalog.party.getPartner”Get one trading partner
POST /rpc/v1/catalog.party.getPartnerAlso 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.
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.party.getPartner \ -H "Authorization: Bearer $ROASTERY_API_KEY" \ -H "X-Roastery-Org: $ORG_ID" \ -H "Content-Type: application/json" \ -d '{}'catalog.party.getProducer
Section titled “catalog.party.getProducer”Get one producer
POST /rpc/v1/catalog.party.getProducerAlso 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.
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.party.getProducer \ -H "Authorization: Bearer $ROASTERY_API_KEY" \ -H "X-Roastery-Org: $ORG_ID" \ -H "Content-Type: application/json" \ -d '{}'catalog.party.listPartners
Section titled “catalog.party.listPartners”List trading partners
POST /rpc/v1/catalog.party.listPartnersAlso 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.
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.party.listPartners \ -H "Authorization: Bearer $ROASTERY_API_KEY" \ -H "X-Roastery-Org: $ORG_ID" \ -H "Content-Type: application/json" \ -d '{}'catalog.party.listProducers
Section titled “catalog.party.listProducers”List producers
POST /rpc/v1/catalog.party.listProducersAlso 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.
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.party.listProducers \ -H "Authorization: Bearer $ROASTERY_API_KEY" \ -H "X-Roastery-Org: $ORG_ID" \ -H "Content-Type: application/json" \ -d '{}'catalog.party.updatePartner
Section titled “catalog.party.updatePartner”Update a trading partner
POST /rpc/v1/catalog.party.updatePartnerRequires permission catalog.party.write and the core module on the organization’s plan.
Request
Section titled “Request”| 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 |
Example
Section titled “Example”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 '{}'catalog.party.updateProducer
Section titled “catalog.party.updateProducer”Update a producer
POST /rpc/v1/catalog.party.updateProducerRequires permission catalog.party.write and the core module on the organization’s plan.
Request
Section titled “Request”| 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 |
Example
Section titled “Example”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 '{}'