SeloraXDEVELOPERS

Permissions Reference

Permissions Reference

Permissions (scopes) control what data your app can access through the API. They are requested during app registration and granted when a merchant installs your app.

API Scopes

These scopes are used in the OAuth flow and when creating Custom Apps.

Data Access Scopes

ScopeGrants Access To
read:ordersView orders, order details, line items, and order history
write:ordersCreate orders, update order status, manage fulfillment
read:productsView products, variants, categories, and pricing
write:productsCreate, update, and delete products and variants
read:customersView customer profiles, contact info, and purchase history
write:customersCreate and update customer records
read:inventoryView stock levels and inventory locations
write:inventoryAdjust stock quantities and manage inventory
read:storeView store settings, domains, currency, and configuration
write:storeUpdate store settings
read:shippingView shipping zones, rates, and 3PL configurations
write:shippingUpdate shipping settings and manage fulfillment providers
read:discountsView discount codes, promotions, and rules
write:discountsCreate, update, and delete discount codes
read:analyticsView store analytics, traffic data, and reports

Special Scopes

ScopeGrants Access To
billingCreate charges, subscriptions, wallet operations, and manage billing for your app
read:billingView billing history and charge status (read-only)
manage:messagingSend SMS, email, and push notifications to customers on behalf of the merchant

Scope Enforcement

Every API endpoint requires a specific scope. If your app doesn't have the required scope, the API returns:

{
  "message": "Insufficient scope. Required: read:orders",
  "code": "insufficient_scope",
  "required_scope": "read:orders",
  "status": 403
}

Scope-to-Endpoint Mapping

Orders

EndpointRequired Scope
GET /api/apps/v1/ordersread:orders
GET /api/apps/v1/orders/:order_idread:orders
POST /api/apps/v1/orderswrite:orders
PUT /api/apps/v1/orders/:order_idwrite:orders
PUT /api/apps/v1/orders/:order_id/statuswrite:orders

Products

EndpointRequired Scope
GET /api/apps/v1/productsread:products
GET /api/apps/v1/products/:product_idread:products
POST /api/apps/v1/productswrite:products
PUT /api/apps/v1/products/:product_idwrite:products
DELETE /api/apps/v1/products/:product_idwrite:products
POST /api/apps/v1/products/:product_id/variantswrite:products
PUT /api/apps/v1/products/:product_id/variants/:sku_idwrite:products
DELETE /api/apps/v1/products/:product_id/variants/:sku_idwrite:products
POST /api/apps/v1/products/:product_id/imageswrite:products

Categories

EndpointRequired Scope
GET /api/apps/v1/categoriesread:products
GET /api/apps/v1/categories/:category_idread:products
POST /api/apps/v1/categorieswrite:products
PUT /api/apps/v1/categories/:category_idwrite:products
DELETE /api/apps/v1/categories/:category_idwrite:products

Customers

EndpointRequired Scope
GET /api/apps/v1/customersread:customers
GET /api/apps/v1/customers/:user_idread:customers
POST /api/apps/v1/customerswrite:customers
PUT /api/apps/v1/customers/:user_idwrite:customers
DELETE /api/apps/v1/customers/:user_idwrite:customers
GET /api/apps/v1/customers/:user_id/ordersread:customers

Discounts

EndpointRequired Scope
GET /api/apps/v1/discountsread:discounts
GET /api/apps/v1/discounts/:discount_idread:discounts
GET /api/apps/v1/discounts/validate/:coderead:discounts
POST /api/apps/v1/discountswrite:discounts
PUT /api/apps/v1/discounts/:discount_idwrite:discounts
DELETE /api/apps/v1/discounts/:discount_idwrite:discounts

Inventory

EndpointRequired Scope
GET /api/apps/v1/inventoryread:inventory
GET /api/apps/v1/inventory/:product_idread:inventory
PUT /api/apps/v1/inventory/:product_idwrite:inventory
POST /api/apps/v1/inventory/:product_id/adjustwrite:inventory

Store

EndpointRequired Scope
GET /api/apps/v1/storeread:store

Billing

EndpointRequired Scope
POST /api/apps/v1/billing/chargesbilling
POST /api/apps/v1/billing/subscriptionsbilling
POST /api/apps/v1/billing/wallet/topupbilling
GET /api/apps/v1/billing/charges/:charge_idbilling
GET /api/apps/v1/billing/charges/activebilling
POST /api/apps/v1/billing/usage-chargesbilling
GET /api/apps/v1/billing/usage-chargesbilling
GET /api/apps/v1/billing/walletbilling
POST /api/apps/v1/billing/wallet/debitbilling
GET /api/apps/v1/billing/wallet/transactionsbilling

Webhooks

EndpointRequired Scope
GET /api/apps/v1/webhooksNo scope required (app-level access)
POST /api/apps/v1/webhooksNo scope required (app-level access)
DELETE /api/apps/v1/webhooks/:subscription_idNo scope required (app-level access)

Webhook Event Topics by Scope

The event topics your app can subscribe to depend on the scopes your app has been granted. The platform does not enforce topic-to-scope restrictions at the subscription level, but the payload will be filtered based on your permissions (see Webhook Payload Filtering below).

Event TopicRelated ScopeDescription
order.createdread:ordersNew order placed
order.updatedread:ordersOrder details modified
order.status_changedread:ordersOrder status transition
product.createdread:productsNew product added
product.updatedread:productsProduct details modified
product.deletedread:productsProduct removed
customer.createdread:customersNew customer account
customer.updatedread:customersCustomer record modified
inventory.updatedread:inventoryStock levels changed
app.installed--App installed on a store
app.uninstalled--App removed from a store
charge.createdbillingNew billing charge created
charge.activatedbillingCharge approved and paid
charge.declinedbillingCharge declined by merchant
charge.cancelledbillingCharge cancelled
charge.expiredbillingCharge expired (48h timeout)
charge.payment_failedbillingPayment gateway failure
subscription.renewal_pendingbillingRecurring renewal upcoming

App Lifecycle Events

app.installed and app.uninstalled events do not require any specific scope. All apps receive these events automatically.


Requesting Scopes

Platform Apps

Specify scopes in your app configuration's requested_scopes field. When a merchant installs your app, they see the requested scopes and choose to grant or deny them.

Only request scopes your app actually needs. Requesting unnecessary scopes reduces merchant trust and install rates.

Custom Apps

Select scopes during app creation in the dashboard wizard. You can update scopes later from Settings > Apps > Manage.

Webhook Payload Filtering

Merchant-created webhooks (from the dashboard Webhooks tab) support permission-based payload filtering. This controls which data fields are included in webhook payloads.

App vs Merchant webhooks

App-created webhooks (auto-created on install) receive unfiltered payloads — they have full access to all fields. Payload filtering only applies to merchant-created webhook subscriptions.

Webhook Permissions

When a merchant creates a webhook subscription from the dashboard, they can select these payload permissions:

PermissionWhat it includesFields removed if missing
read_ordersOrder totals, tracking, address, line itemstotal, grand_total, tracking_id, tracking_code, address, items
read_productsProduct details and pricingproduct_title, product_price, variants, sku
read_customersCustomer contact informationcustomer_name, customer_phone, customer_email, email, phone
read_inventoryStock and quantity dataquantity, stock, inventory_quantity

Example

A webhook subscription with only read_orders permission receiving an order.status_changed event:

Full payload (app webhook):

{
  "data": {
    "order_id": 1045,
    "status": "confirmed",
    "total": 1460.00,
    "customer_name": "Rahim Ahmed",
    "customer_phone": "+8801712345678"
  }
}

Filtered payload (merchant webhook with only read_orders):

{
  "data": {
    "order_id": 1045,
    "status": "confirmed",
    "total": 1460.00
  }
}

Customer fields are removed because the read_customers permission was not granted.

Extension Scopes

Extensions inherit their parent app's OAuth scopes. When a sandbox extension calls selorax.api.get('/apps/v1/orders'), the API proxy checks that the app has read:orders. No additional scopes are needed specifically for extensions — the app's existing scopes apply.

Extension FeatureRequired Scope
API proxy requests (read)Matching read:* scope for the resource
API proxy requests (write)Matching write:* scope for the resource
Metafield read/writeNo special scope (app-scoped by default)
Billing from extensionbilling
Webhook managementNo scope required (app-level access)

Extension deployment and management use client credentials (X-Client-Id + X-Client-Secret) and do not require OAuth scopes. See Extensions for details.


Best Practices

  • Least privilege — Request only the scopes your app needs. You can always add more scopes later (merchants will need to re-authorize).
  • Check scopes at runtime — The token exchange response includes a scope field listing what was actually granted. Verify it contains what your app needs.
  • Handle scope changes — If a merchant re-installs with different scopes, your stored scopes may be outdated. Always check the latest scope from the installation data.
  • Document your scope usage — In your app's description, explain why each scope is needed. Merchants are more likely to install apps that justify their permissions.