Access

The following endpoints allow you to view and manage end-user access to the specified merchant/domain as well as instantly provision credentials for end-users to access our portal.

Get access

get

Retrieves all users that have access to the merchant's company

Authorizations
AuthorizationstringRequired

API key generated in Clym Partner Portal.

Query parameters
merchant_idstringOptional

Either a merchant ID or a domain ID is required

domain_idstringOptional
Responses
200

An array with all users

application/json
get
/portal/instance/access/users
GET /api/portal/instance/access/users HTTP/1.1
Host: partners.clym.io
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
200

An array with all users

{
  "meta": {
    "current_page": 1,
    "next_page": 1,
    "prev_page": 1
  },
  "result": [
    {
      "id": "c4111c2607214aaaa9349371wkflsagx",
      "email": "[email protected]",
      "first_name": "John",
      "last_name": "Doe",
      "role": "OWNER",
      "is_active": true,
      "created_by": {
        "id": "text",
        "email": "[email protected]",
        "first_name": "text",
        "last_name": "text"
      }
    }
  ]
}

Grant access

post

Grant company access to the specified user with the specified role. The system will send an invitation email to the newly created user.

Authorizations
AuthorizationstringRequired

API key generated in Clym Partner Portal.

Body
emailstring · emailRequired

The target email address

Example: [email protected]
rolestring · enumRequired

The role the user will be granted in the company.

Example: OWNERPossible values:
Responses
200

Merchant added to the partner account

application/json
post
/portal/instance/access/users
POST /api/portal/instance/access/users HTTP/1.1
Host: partners.clym.io
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 39

{
  "email": "[email protected]",
  "role": "OWNER"
}
200

Merchant added to the partner account

{
  "result": {
    "id": "c4111c2607214aaaa9349371wkflsagx",
    "email": "[email protected]",
    "first_name": "John",
    "last_name": "Doe",
    "role": "OWNER",
    "is_active": true,
    "created_by": {
      "id": "text",
      "email": "[email protected]",
      "first_name": "text",
      "last_name": "text"
    }
  }
}

Provision access

post

Instantly provision the specified user and role in the company and return a magic link. This performs just-in-time user access creation or access updating.

Authorizations
AuthorizationstringRequired

API key generated in Clym Partner Portal.

Query parameters
merchant_idstringOptional

Either a merchant ID or a domain ID is required

domain_idstringOptional
Body
emailstring · emailRequired

The email account of the user you want to provision

rolestring · enumRequired

The role to assign to the specified user

Possible values:
access_switchbooleanOptional

Set this field to false to disable switching between companies for the target user.

Default: true
Responses
200

The user access information and authentication information

application/json
post
/portal/instance/access/users/provision
POST /api/portal/instance/access/users/provision HTTP/1.1
Host: partners.clym.io
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 62

{
  "email": "[email protected]",
  "role": "OWNER",
  "access_switch": true
}
200

The user access information and authentication information

{
  "result": {
    "id": "text",
    "email": "[email protected]",
    "role": "OWNER",
    "is_active": true,
    "login_url": "https://example.com"
  }
}

Get access

get

Retrieve information about a user's access

Authorizations
AuthorizationstringRequired

API key generated in Clym Partner Portal.

Path parameters
userIdstringRequired

User id

Query parameters
merchant_idstringOptional

Either a merchant ID or a domain ID is required

domain_idstringOptional
Responses
200

The user access information

application/json
get
/portal/instance/access/users/{userId}
GET /api/portal/instance/access/users/{userId} HTTP/1.1
Host: partners.clym.io
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
200

The user access information

{
  "result": {
    "id": "c4111c2607214aaaa9349371wkflsagx",
    "email": "[email protected]",
    "first_name": "John",
    "last_name": "Doe",
    "role": "OWNER",
    "is_active": true,
    "created_by": {
      "id": "text",
      "email": "[email protected]",
      "first_name": "text",
      "last_name": "text"
    }
  }
}

Update access

put

Update access information for the specified user

Authorizations
AuthorizationstringRequired

API key generated in Clym Partner Portal.

Path parameters
userIdstringRequired

User id

Query parameters
merchant_idstringOptional

Either a merchant ID or a domain ID is required

domain_idstringOptional
Body
rolestring · enumOptional

The new role to assign to the user

Possible values:
is_activebooleanOptional

Enables or disables the user's access in the company.

Responses
200

Acknowledgement that request was successful.

application/json
Responseobject
put
/portal/instance/access/users/{userId}
PUT /api/portal/instance/access/users/{userId} HTTP/1.1
Host: partners.clym.io
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 33

{
  "role": "OWNER",
  "is_active": true
}
200

Acknowledgement that request was successful.

{}

Delete access

delete

Removes the specified user's access in the company.

Authorizations
AuthorizationstringRequired

API key generated in Clym Partner Portal.

Path parameters
userIdstringRequired

User id

Query parameters
merchant_idstringOptional

Either a merchant ID or a domain ID is required

domain_idstringOptional
Responses
200

User access deletion confirmation

application/json
delete
/portal/instance/access/users/{userId}
DELETE /api/portal/instance/access/users/{userId} HTTP/1.1
Host: partners.clym.io
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
200

User access deletion confirmation

{
  "result": {}
}

Last updated