Skip to main content

Permission List

Our API works with access permissions that define user interactions like edit, add or remove, this endpoint returns a paginated list of these permissions.

Permission List [GET]

BASE URL
https://api-b2b-hml.carbonext.com.br/v1/permissions?page=1&page-size=20

This request returns a paginated list with all available permissions. These permissions can be attached to users and/or customer_applications (API keys).

Permission List

PermissionDescription
orders_readList Orders
orders_writeAdd, edit or remove orders
customer_applications_readList Customers
customer_applications_writeAdd, edit or remove customers
financial_writeAdd invoices
financial_readList Invoices
users_writeAdd, edit, or remove users
users_readList Users
subscriptions_writeAdd, edit, or suspend subscriptions
subscriptions_readList subscriptions
certificates_readList Certificates

Response Attributes

AttributesDescription
ItemsA list of permissions

Example Request

var axios = require('axios');

var config = {
method: 'get',
url: 'https://api-b2b-hml.carbonext.com.br/v1/permissions?page=1&page-size=20',
headers: {
'Authorization': 'Bearer <access_token>'
}
};

axios(config)
.then(function (response) {
console.log(JSON.stringify(response.data));
})
.catch(function (error) {
console.log(error);
});

Example Response


[
{
"id": "c56452df-18fe-474b-9cab-82080af3e902",
"name": "users_write",
"description": "Criar/Remover usuários",
"composite": false,
"clientRole": false,
"containerId": "CO2FREE",
"attributes": null
},
{
"id": "497efb5a-25eb-434f-9a2a-2e3aa6b2e6e1",
"name": "certificates_read",
"description": "Visualizar certificados",
"composite": false,
"clientRole": false,
"containerId": "CO2FREE",
"attributes": null
},
{
"id": "4f3ca574-0b89-4a92-83fa-794edcad6b76",
"name": "customer_applications_write",
"description": "Criar/Remover Chaves de API",
"composite": false,
"clientRole": false,
"containerId": "CO2FREE",
"attributes": null
}
]
PARAMS
page: 1
page-size: 20