Documentation
Feedback
Guides
API Reference

Guides
Guides
B2B
B2B Buyer Portal

Storefront Roles

Learn how to manage user access and roles within the storefront using the Storefront Permissions API for B2B scenarios.

This feature is available only for stores using B2B Buyer Portal, currently available for selected accounts.

The Storefront Roles API provides a structured way to manage user access and roles within the storefront. It enables organizations to define and enforce authorization policies by controlling which actions users can perform.

The Storefront Roles API allows you to:

  • Assign and revoke roles for storefront users.
  • Validate access by checking whether a user has permission to perform a specific action.
  • Retrieve details about user roles and permissions.
  • Manage access to resources such as orders, addresses, authentication settings, and payment methods.

Key concepts

  • Storefront resources: Fine-grained permissions that define a specific capability in the storefront (for example, PlaceOrders, ApproveOrders, ManageAddresses).
  • Storefront roles: Logical groupings of resources that represent common permission sets (for example, Buyer, Order Approver, Organizational Unit Admin).
  • Storefront users: Storefront identities (customers or organization members) to whom roles and resources are assigned.

Use cases

This functionality is particularly relevant in B2B contexts, where multiple users within the same organization may require different access levels based on their role in the purchasing process.

The Storefront Roles API supports a wide range of business scenarios by enabling control over user access, such as:

  • Granting buyers permission to place orders while restricting order approvals to designated approvers.
  • Allowing managers to oversee all orders within their organizational unit.
  • Enabling administrators to configure organizational structures, contracts, and user access.

Before you begin

  • All endpoints require the Storefront Roles feature to be enabled on your account. Requests sent to accounts without this feature enabled return a “Feature not enabled for this account” error.

  • Any user or API key must have the appropriate License Manager resources to be able to successfully run requests to the License Manager API as listed in the table below. Otherwise, they will receive a status code 403 error.

ProductCategoryResourceAssociated endpoints
License ManagerServices access controlView Storefront User PermissionsGET Check storefront user resource access
GET Get storefront user roles
GET Fetch storefront user roles by email
GET Fetch storefront user details
License ManagerServices access controlEdit Storefront User PermissionsPOST Assign storefront roles
POST Assign one storefront role
DELETE Revoke storefront roles
DELETE Remove storefront user

To learn more about machine authentication at VTEX, see Authentication overview.

Available storefront resources

The following resource keys are available in the system:

Resource KeyDescription
ManageOrganizationAndContractAllows management of the organization's structure, contracts, and related settings.
ManageOrganizationHierarchyAllows creation, editing, and restructuring of Organization Units within the buyer organization hierarchy.
ManageUsersAllows creation, editing, and removal of users within the buyer organization.
ManageBuyingPoliciesAllows creation and configuration of buying policies within the organization.
ViewBuyingPoliciesAllows viewing existing buying policies without editing permissions.
ManageBudgetsAllows creation and management of budgets and budget allocations.
ViewBudgetAllows viewing budget information without editing permissions.
ManageAccountingFieldsAllows configuration and management of accounting or custom financial fields.
ManageQuotesAllows management of quote requests and related negotiation flows.
PlaceOrdersGrants the ability to create and submit orders within the system.
ViewMyContractOrdersEnables users to see orders placed under their assigned contract.
ViewMyOrgUnitOrdersAllows users to view all orders within their organizational unit.
ModifyOrdersProvides permission to use the change order feature for all orders that the user has access to.
ApproveOrdersGrants the ability to approve or reject orders based on predefined workflows.
ManageAddressesAllows adding a new address during checkout and saving it for the contract or organization unit.
UseAdHocCardGrants permission to use a new credit card at checkout.
SavePrivateCardGrants permission to save a new card for the user's personal use only.
ViewProfileAllows access to view profile information.
ManageAuthenticationProvides access to authentication settings.
ViewMyCardsEnables users to view their saved payment cards.
ViewAddressesAllows users to view and update their saved addresses.

Predefined storefront roles

The system comes with these predefined storefront roles, each with specific permissions:

Predefined storefront roleStorefront role IDDescriptionAssociated resources
Organizational Unit Admin1Manages the organization's structure, contracts, and related settings.ManageOrganizationAndContract, ManageUsers, ManageBuyingPolicies, ViewBuyingPolicies, ManageBudgets, ViewBudgets, ManageAccountingFields, ManageQuotes, ManageOrganizationHierarchy
Order Approver2Can approve or reject orders based on predefined workflows.ApproveOrders
Order Modifier3Can use the change order feature for all orders they have access to.ModifyOrders
Buyer4Can create and submit orders within the system.PlaceOrders
Personal Cards User5Can use a new credit card at checkout and save cards for personal use only.UseAdHocCard, SavePrivateCard
Contract Manager6Can view orders placed under their assigned contract.ViewMyContractOrders
Buyer Organization Manager7Can view all orders within their organizational unit.ViewMyOrgUnitOrders
Contract Viewer8Can view profiles, payment cards, and addresses.ViewProfile, ViewMyCards, ViewAddresses
Address Manager9Can add and manage addresses during checkout.ManageAddresses, ViewAddresses
Super Buyer Admin16Has full administrative control over the buyer organization structure, including management of Organization Units and hierarchical configuration.ManageOrganizationHierarchy
Contributors
1
Photo of the contributor
Was this helpful?
Yes
No
Suggest Edits (GitHub)
Contributors
1
Photo of the contributor
Was this helpful?
Suggest edits (GitHub)
On this page