API Credentials
Overview
The API Credentials panel, available in API Credentials in the Developers section of the menu allows you to generate an API key (made of the client ID and client secret) to authenticate and get access to the Fynapse API. The API key is, by default, valid for 90 days. The panel also allows you to remove a particular API key and replace it with a new one.
There are two types of credentials:
- User - scoped to the permissions of its Owner. Any API Call made with them will inherit the Owner permissions.
- Service - these credentials will allow for either allowing full API access or to be scoped to particular permissions.
Both credentials are immutable, they can’t be changed once created.
Keep in mind that an API key inherits all permissions from the user creating it. That is why system administrators should not create API keys for other users, but each user should do it on their own. It is not recommended to share API keys with other users since all actions done using these keys will be logged for the user who generated them.
The API key generated in Fynapse can also be used for integrating with external tools and systems. For systemic integration the recommended approach is to use Service Credentials.
API Credentials
The API Credentials panel consists of two sections: User credentials and Service credentials.
A single Create API credentials action is shared for both.
Creating new API credentials
After using Create API credentials action, a dialog will appear to ask for the following:
-
Owned by - who will own the credentials:
- You - the owner will be the User who generated the credentials. Credentials will inherit its Owner permissions.
- Service account - no single User owns these credentials. These credentials can be generated and revoked by Fynapse Security Administrator or Fynapse System Administrator.
-
Name - an optional field that can be used to inform the purpose of these credentials.
-
In case of Service credentials the next step is to scope the permissions. By default, full permissions are assigned to the credentials. This can be changed by choosing Restricted option. With this option, each API permission needs to be individually granted.
When choosing All permissions, the system will automatically allow use of all future APIs.
When choosing Restricted permissions, even if all permissions are granted when creating the credentials, new APIs will not automatically be granted.
The credentials will be generated after confirming with Create action. After credentials are generated a dialog will be presented displaying the Client ID and Client Secret. Both can be copied into clipboard.
It is essential to safely record the Client Secret - it will never be shown again.
User Credentials
These credentials will allow to use REST APIs that are permitted to the User who generated them. This section contains a grid of credentials that are already created. The grid has the following columns:
- Name - (Optional) a name assigned to API Key
- Client ID - a part of an API key and a unique identifier of a particular API user
- Created - a date when the credentials were created
- Last used - a timestamp of the last authentication made with this client_id - it can take up to 10 minutes to update this column.
- Expiration date - a date until the API key is valid. The API key is, by default, valid for 90 days.
- Status - the API key status. It can be:
- Valid - informs that the particular API key is valid
- Suspended - informs that a user account associated with the specific API key is disabled
- Expired - informs that the particular API key reached its expiration date and cannot be used anymore
- Actions - use it to remove a selected API key
Service Credentials
These credentials will allow to use REST APIs, but they are not scoped to a particular User. These are system-wide and can be managed by Administrators. The grid has the following columns:
- Name - (Optional) a name assigned to API Key
- Client ID - a part of an API key and a unique identifier of a particular API user
- Permissions - a list of permissions assigned to API Key
- Created - a date when the credentials were created
- Last used - a timestamp of the last authentication made with this client_id - it can take up to 10 minutes to update this column.
- Expiration date - a date until the API key is valid. The API key is, by default, valid for 90 days.
- Status - the API key status. It can be:
- Valid - informs that the particular API key is valid
- Expired - informs that the particular API key reached its expiration date and cannot be used anymore
- Actions - use it to remove a selected API key
Service Credentials permissions
If the credentials were generated with All options, then the service credentials will have the following permissions:
- admin - access to all modifiable REST APIs
- readonly - access to all read-only REST APIs
With the Restricted option, the following permissions can be granted individually. The tables below, grouped in the same way as the API Reference, show which API endpoints each permission allows. A writer permission automatically includes its corresponding reader permission for the same API.
Data Entity Metadata
Data Ingestion
Data Extraction
Processing Statistics
Bulk Configuration
Events
Tutorials
How to Create User Credentials?
You can generate and then use many API keys simultaneously.
Each user should generate their own API key and should not share it with other users. Since the key is uniquely assigned to the user who generates it, and inherits that user’s permissions. Additionally, all actions done using this key will be logged for this user.
- Log in to your Fynapse account.
- Go to Developers > API Credentials.
- In the API Credentials panel, click the Create API credentials button.
- Under Owned by, choose You.
- (Optional) Name the new API key.
- Click the Create button.
- A Save your secret panel will be shown, where both client_id and client_secret are presented.
- Acknowledge that you have safely recorded the secret and click the Done button.
How to create credentials that allow access to all REST APIs?
This option is available only to Fynapse Security Administrator and Fynapse System Administrator
- Log in to your Fynapse account (as System or Security Administrator).
- Go to Developers > API Credentials.
- In the API Credentials panel, click the Create API credentials button.
- Under Owned by, choose Service account.
- (Optional) Name the new API key.
- Under Permissions, choose All.
- Click the Create button.
- A Save your secret panel will be shown, where both client_id and client_secret are presented.
- Acknowledge that you have safely recorded the secret and click the Done button.
How to create credentials that are scoped to particular REST APIs?
This option is available only to Fynapse Security Administrator and Fynapse System Administrator
- Log in to your Fynapse account (as System or Security Administrator).
- Go to Developers > API Credentials.
- In the API Credentials panel, click the Create API credentials button.
- Under Owned by, choose Service account.
- (Optional) Name the new API key.
- Under Permissions, choose Restricted.
- Select the permissions appropriate for the credentials you are creating.
- Click the Create button.
- A Save your secret panel will be shown, where both client_id and client_secret are presented.
- Acknowledge that you have safely recorded the secret and click the Done button.
How to Remove an API Key?
- Log in to your Fynapse account.
- Go to Developers > API Credentials.
- In the User credentials or in Service credentials grid, find the API key you want to remove.
- Click the trash bin icon.
The action cannot be reversed.
- Confirm the action by clicking the Delete button. The API key will be removed, and it will be impossible to use it again for authentication. You will not be able to use the Fynapse API until you generate a new API key.