Skip to main content

Client Registration API

Please note that this API is in Private Preview and is not available to the general public at this time. More information about release phases may be found here

API Documentation

The Client Registration API documentation can be found at https://api.vegacloud.io/identity/clientregistration/docs#/.

Purpose

An API Client Registration allows your client application (such as a script or bot) to interact securely with Vega Platform APIs and services by registering it with the Vega Authentication System. This registration assigns a unique identity to your application, functioning like a digital badge that authenticates your application's requests to Vega services. Your application is secured via a Client Secret Key, a confidential key that verifies your application's identity when accessing Vega resources. Treat this Client Secret Key as a sensitive piece of information, ensuring that only your application has the access needed to communicate with Vega services securely.

API Client Registration

Found under Settings > API Client Registration

This tab allows a user to create an API Client Registration in order to access the Client Registration API.

NOTE: A user can only see this tab when assigned one of the following roles: data_reader, org_global_admin, or org_owner.

Generate an API Client Registration

In order to generate an API Client Registration, click the "+ API Client Registration" button:

apiclientregistration-1

Enter a name for the client registration, as well as an expiration time, and click the Save button:

apiclientregistration-2

NOTE: Expiration can be set to 1 day, 1 week, 30 days, 90 days, 120 days, 1 year, or 2 years.

Once the client registration is created, ensure that you save the Client ID and Client Secret Key, as the secret will not be shown again. You can copy and/or download as a JSON file for safe keeping.

Acknowledge that you have copied the client information by checking the "I have copied the client information" box, then click the Done button.

apiclientregistration-3

All saved API Client Registrations will be shown in the table, listing details for each client registration. There is a limit of 5 client registrations per user. You can delete inactive client registrations by clicking the delete icon in the 'Actions' column.

apiclientregistration-4

How to use an API Client Registration

Once you have generated a Client Registration for your application, send the Client ID and Client Secret Key to the following endpoint in order to return an access token:

curl -X POST 'https://auth.vegacloud.io/realms/<your-realm-name>/protocol/openid-connect/token' \
-H 'Content-Type: application/x-www-form-urlencoded' \
--data-urlencode 'grant_type=client_credentials' \
--data-urlencode 'client_id=<your-client-id>' \
--data-urlencode 'client_secret=<your-client-secret>'

Then, send the access token as the Authorization: Bearer header when calling a Vega API endpoint.

curl -X GET 'https://api.example.com/protected/resource' \
-H 'Authorization: Bearer <your_access_token>'