Skip to main content
Every Admin API resource is exposed as a property on the client (client.orders, client.products, …). Collection resources follow a consistent CRUD shape — list, get, create, update, delete — plus resource-specific actions. Nested resources take the parent ID as the first argument: For the underlying HTTP surface — every endpoint with the API key scope it requires — see the Admin API endpoint index.
// Top-level
const order = await client.orders.get('order_xxx')

// Nested — parent ID first
const payments = await client.orders.payments.list('order_xxx')
await client.orders.payments.capture('order_xxx', 'payment_xxx')

// Nested create
await client.customers.addresses.create('cus_xxx', {
  first_name: 'Jane',
  last_name: 'Doe',
  address1: '350 Fifth Avenue',
  city: 'New York',
  postal_code: '10118',
  country_iso: 'US',
  state_abbr: 'NY',
  is_default_shipping: true,
})

Catalog

ClientEndpoints
client.productsCRUD, clone, and bulk operations (bulkStatusUpdate, bulkAddToCategories / bulkRemoveFromCategories, bulkAddToChannels / bulkRemoveFromChannels, bulkAddTags / bulkRemoveTags, bulkDestroy). Nested: media, variants (with their own media).
client.variantsTop-level variant search across products (list, get).
client.optionTypesCRUD on option types and their values.
client.categoriesList categories.
client.tagsAutocomplete tag names per taggable type.
client.taxCategoriesCRUD on tax categories.

Orders & fulfillment

ClientEndpoints
client.ordersList, get, create, update, delete, complete, cancel, approve, resume, resendConfirmation. Nested: items, payments (incl. capture / void), fulfillments (incl. fulfill / cancel / resume / split), refunds, giftCards, storeCredits, adjustments.

Customers

ClientEndpoints
client.customersCRUD plus bulk group operations (bulkAddToGroups / bulkRemoveFromGroups) and bulk tags. Nested: addresses, creditCards, storeCredits.
client.customerGroupsCRUD on customer groups.

Pricing & promotions

ClientEndpoints
client.pricesCRUD plus bulkUpsert / bulkDestroy for variant prices.
client.priceListsCRUD, activate / deactivate, and price-list rule types.
client.promotionsCRUD. Nested: actions, rules, couponCodes.
client.promotionActionsLookup of available action types and calculators.
client.promotionRulesLookup of available rule types.
client.giftCardsCRUD on gift cards.
client.giftCardBatchesList, get, and create gift card batches.
client.storeCreditCategoriesList and read store credit categories.

Inventory

ClientEndpoints
client.stockLocationsCRUD on stock locations.
client.stockItemsList, get, update, delete stock items.
client.stockTransfersList, get, create, delete stock transfers.

Sales channels

ClientEndpoints
client.channelsCRUD plus addProducts / removeProducts.
client.marketsCRUD on markets.

Store configuration

ClientEndpoints
client.storeStore profile (get, update).
client.paymentMethodsCRUD plus types (available gateway types).
client.countriesList and read countries (for address dropdowns).
client.customFieldDefinitionsCRUD on custom field definitions.
client.exportsCreate and track CSV exports (products, orders, customers, …).
client.directUploadsPre-signed Active Storage uploads (used by media flows).

Platform & access

ClientEndpoints
client.authLogin (email/password or identity provider), cookie-driven refresh, logout, invitation lookup/acceptance — see Authentication.
client.meCurrent admin user + permissions.
client.adminUsersList, get, update, delete admin users.
client.invitationsStaff invitations — list, get, create, delete, resend.
client.rolesList and read roles.
client.apiKeysCRUD plus revoke for API keys.
client.allowedOriginsCRUD on CORS allowed origins.
client.webhookEndpointsCRUD, sendTest, enable / disable. Nested: deliveries (list, get, redeliver).
client.dashboardSales analytics.

Custom fields

Resources that support custom fields (products, variants, orders, customers, categories, option types) expose a customFields accessor taking the parent ID first:
await client.products.customFields.list('prod_xxx')
await client.products.customFields.create('prod_xxx', {
  custom_field_definition_id: 'cfd_xxx',
  value: 'limited-edition',
})
The generic escape hatch covers any owner type:
await client.customFields('Spree::Product', 'prod_xxx').list()

Adding your own resources

The resource map grows with your store. The spree generate api_resource generator scaffolds new Admin API endpoints (model, serializers, controllers, routes, specs) in one command — then call them from the SDK with a custom fetch or raw request, or generate a typed client for them.