Cert++
Close

OCAPI settings document structure and client-level fields

Key Takeaway

OCAPI grants no permissions by default. Until you grant a client access to a resource in the OCAPI settings JSON, OCAPI declines that client's requests with HTTP 401 (Unauthorized).

OCAPI settings are JSON documents, edited in Business Manager, that decide which client applications may call which Open Commerce API resources and how. The document is layered. A top-level configuration document holds a list of clients. Each client carries its own ID, allowed origins, custom response headers and resource permissions.

How to edit OCAPI settings
  1. In Business Manager, go to "Administration > Site Development > Open Commerce API Settings".
  2. In the "Select type" field, choose the API type.
  3. In the "Select context" field, choose the context: Global or a site name.
  4. Edit the JSON document in the text field.
  5. Click "Save".

Saved settings are cached for up to three minutes before they become effective, so a change may not work right after you click Save.

B2C Commerce Developer Study Guide

Checklist progress

0/237Learned

Prepare for the Exam

Play Today's Certle

Study Community

Ask questions and get the latest info from other B2C Commerce Developer studiers.