Applications

Create and manage applications in the tenant.

Get Apps list.Deprecated

Return the list of apps of the tenant. Deprecated in favor of the new endpoint api/v1/apps.

SecuritybearerAuth
Request
query Parameters
roles
Array of strings (Role)

Filter the returned entities to only those with the required role

Items Enum: "admin" "department_admin" "researcher" "editor" "viewer" "research_manager" "ml_engineer"
Example: roles=viewer
onlyCreatedByMe
boolean

Filter the returned entities to only those that created by the requesting subject

Responses
200

The complete set of permissions.

400

Bad request.

401

Unauthorized

403

Forbidden

500

unexpected error

503

unexpected error

get/v1/k8s/apps
Response samples
application/json
[
  • {
    }
]

Create a new app.Deprecated

Create a new app and assign it with a client secret. This endpoint requires ADMIN role. Deprecated in favor of the new endpoint api/v1/apps.

SecuritybearerAuth
Request
Request Body schema: application/json
required
entityType
string (AuthEntityType)

The type of authentication entity.

Enum: "regular-user" "sso-user" "app" "group" "internal-user" "super-admin"
tenantId
integer <int32> (TenantId)

The id of the tenant.

userId
string <uuid> (UserId)

Unique identifier of the user

permitAllClusters
boolean
permittedClusters
Array of strings <uuid> (ClusterId)

A list of clusters that the user or application can access.

roles
Array of strings (Role)
Items Enum: "admin" "department_admin" "researcher" "editor" "viewer" "research_manager" "ml_engineer"
createdAt
string <date-time>

The creation date of the application.

clientId
string

The client ID of the application.

name
required
string

The name of the application.

revoked
boolean

Whether the application has been revoked.

Responses
200

The complete set of permissions.

400

Bad request.

401

Unauthorized

403

Forbidden

500

unexpected error

503

unexpected error

post/v1/k8s/apps
Request samples
application/json
{
  • "entityType": "regular-user",
  • "tenantId": 1001,
  • "userId": "4008188b-ab50-4aa5-a3f2-b78091ccf92d",
  • "permitAllClusters": false,
  • "permittedClusters": [
    ],
  • "roles": [
    ],
  • "createdAt": "2021-12-14T16:04:15.099Z",
  • "clientId": "6d2894ba-f998-4039-bba1-caba57caf681",
  • "name": "MyApplication",
  • "revoked": false
}
Response samples
application/json
{
  • "entityType": "regular-user",
  • "tenantId": 1001,
  • "userId": "4008188b-ab50-4aa5-a3f2-b78091ccf92d",
  • "permitAllClusters": false,
  • "permittedClusters": [
    ],
  • "roles": [
    ],
  • "createdAt": "2021-12-14T16:04:15.099Z",
  • "clientId": "6d2894ba-f998-4039-bba1-caba57caf681",
  • "name": "MyApplication",
  • "revoked": false
}

Get app details.Deprecated

Get the details of a given app. This endpoint requires ADMIN, EDITOR or VIEWER role. Deprecated in favor of the new endpoint api/v1/apps/{clientId}.

SecuritybearerAuth
Request
path Parameters
clientId
required
string <uuid> (ClientId)

Unique identifier of the app

Example: 4008188b-ab50-4aa5-a3f2-b78091ccf92d
Responses
200

App details.

400

Bad request.

401

Unauthorized

403

Forbidden

404

The specified resource was not found

500

unexpected error

503

unexpected error

get/v1/k8s/apps/{clientId}
Response samples
application/json
{
  • "entityType": "regular-user",
  • "tenantId": 1001,
  • "userId": "4008188b-ab50-4aa5-a3f2-b78091ccf92d",
  • "permitAllClusters": false,
  • "permittedClusters": [
    ],
  • "roles": [
    ],
  • "createdAt": "2021-12-14T16:04:15.099Z",
  • "clientId": "6d2894ba-f998-4039-bba1-caba57caf681",
  • "name": "MyApplication",
  • "revoked": false
}

Update app details.Deprecated

Update the details of a given app. This endpoint requires ADMIN role. Deprecated in favor of the new endpoint api/v1/apps/{clientId}.

SecuritybearerAuth
Request
path Parameters
clientId
required
string <uuid> (ClientId)

Unique identifier of the app

Example: 4008188b-ab50-4aa5-a3f2-b78091ccf92d
Request Body schema: application/json
required
entityType
string (AuthEntityType)

The type of authentication entity.

Enum: "regular-user" "sso-user" "app" "group" "internal-user" "super-admin"
tenantId
integer <int32> (TenantId)

The id of the tenant.

userId
string <uuid> (UserId)

Unique identifier of the user

permitAllClusters
boolean
permittedClusters
Array of strings <uuid> (ClusterId)

A list of clusters that the user or application can access.

roles
Array of strings (Role)
Items Enum: "admin" "department_admin" "researcher" "editor" "viewer" "research_manager" "ml_engineer"
createdAt
string <date-time>

The creation date of the application.

clientId
string

The client ID of the application.

name
required
string

The name of the application.

revoked
boolean

Whether the application has been revoked.

Responses
200

User updated successfully

400

Bad request.

401

Unauthorized

403

Forbidden

404

The specified resource was not found

500

unexpected error

503

unexpected error

put/v1/k8s/apps/{clientId}
Request samples
application/json
{
  • "entityType": "regular-user",
  • "tenantId": 1001,
  • "userId": "4008188b-ab50-4aa5-a3f2-b78091ccf92d",
  • "permitAllClusters": false,
  • "permittedClusters": [
    ],
  • "roles": [
    ],
  • "createdAt": "2021-12-14T16:04:15.099Z",
  • "clientId": "6d2894ba-f998-4039-bba1-caba57caf681",
  • "name": "MyApplication",
  • "revoked": false
}
Response samples
application/json
{
  • "entityType": "regular-user",
  • "tenantId": 1001,
  • "userId": "4008188b-ab50-4aa5-a3f2-b78091ccf92d",
  • "permitAllClusters": false,
  • "permittedClusters": [
    ],
  • "roles": [
    ],
  • "createdAt": "2021-12-14T16:04:15.099Z",
  • "clientId": "6d2894ba-f998-4039-bba1-caba57caf681",
  • "name": "MyApplication",
  • "revoked": false
}

Delete a App.Deprecated

Delete the given app from the tenant. This endpoint requires ADMIN role. Deprecated in favor of the new endpoint api/v1/apps/{clientId}.

SecuritybearerAuth
Request
path Parameters
clientId
required
string <uuid> (ClientId)

Unique identifier of the app

Example: 4008188b-ab50-4aa5-a3f2-b78091ccf92d
Responses
200

User deleted successfully.

400

Bad request.

401

Unauthorized

403

Forbidden

404

The specified resource was not found

500

unexpected error

503

unexpected error

delete/v1/k8s/apps/{clientId}
Response samples
application/json
{
  • "code": 400,
  • "message": "Required parameter is missing"
}

Re-generate secret of application.Deprecated

Generate a new secret for a given application. This endpoint requires ADMIN role. Deprecated in favor of the new endpoint api/v1/apps/{clientId}/secret.

SecuritybearerAuth
Request
path Parameters
clientId
required
string <uuid> (ClientId)

Unique identifier of the app

Example: 4008188b-ab50-4aa5-a3f2-b78091ccf92d
Responses
200

The secret generated succefully

400

Bad request.

401

Unauthorized

403

Forbidden

404

The specified resource was not found

500

unexpected error

503

unexpected error

post/v1/k8s/apps/{clientId}/secret
Response samples
application/json
{
  • "entityType": "regular-user",
  • "tenantId": 1001,
  • "userId": "4008188b-ab50-4aa5-a3f2-b78091ccf92d",
  • "permitAllClusters": false,
  • "permittedClusters": [
    ],
  • "roles": [
    ],
  • "createdAt": "2021-12-14T16:04:15.099Z",
  • "clientId": "6d2894ba-f998-4039-bba1-caba57caf681",
  • "name": "MyApplication",
  • "revoked": false
}

Get a list of applications.

Retrieve a list of applications.

SecuritybearerAuth
Responses
200

Executed successfully.

400

Bad request.

401

Unauthorized

403

Forbidden

404

The specified resource was not found

500

unexpected error

503

unexpected error

get/api/v1/apps
Response samples
application/json
[
  • {
    }
]

Create an application.

Used to create an application.

SecuritybearerAuth
Request
Request Body schema: application/json
required

Application object to create

name
required
string
Responses
201

Executed successfully.

400

Bad request.

401

Unauthorized

403

Forbidden

404

The specified resource was not found

409

The specified resource already exists

500

unexpected error

503

unexpected error

post/api/v1/apps
Request samples
application/json
{
  • "name": "app123"
}
Response samples
application/json
{
  • "id": "0eeaf222-e503-4f35-9d9c-c419816272e3",
  • "name": "app123",
  • "secret": "asdasidjn9d"
}

Get a list of installer applications.

Retrieve a list of installer applications.

SecuritybearerAuth
Responses
200

Executed successfully.

400

Bad request.

401

Unauthorized

403

Forbidden

500

unexpected error

503

unexpected error

get/api/v1/apps/installer
Response samples
application/json
{
  • "id": "0eeaf222-e503-4f35-9d9c-c419816272e3",
  • "name": "app123",
  • "secret": "asdasidjn9d"
}

Get application by id.

Retrieve the details of an application by id.

SecuritybearerAuth
Request
path Parameters
appId
required
string

The application id to retrieve

Responses
200

Executed successfully.

400

Bad request.

401

Unauthorized

403

Forbidden

404

The specified resource was not found

500

unexpected error

503

unexpected error

get/api/v1/apps/{appId}
Response samples
application/json
{
  • "name": "app123",
  • "createdBy": "test@run.ai",
  • "createdAt": "2020-01-01T00:00:00Z",
  • "updatedAt": "2020-01-01T00:00:00Z",
  • "enabled": true,
  • "tenantId": 1234567890,
  • "lastLogin": "2020-01-01T00:00:00Z",
  • "id": "3434c-12323ab-4ce2ea6-b44fc-db344d"
}

Update application details by id.

Use to update the details of an application by id.

SecuritybearerAuth
Request
path Parameters
appId
required
string

The application id to retrieve

Request Body schema: application/json

Application object that needs to be updated.

enabled
required
boolean
Responses
200

Executed successfully.

400

Bad request.

401

Unauthorized

403

Forbidden

404

The specified resource was not found

500

unexpected error

503

unexpected error

patch/api/v1/apps/{appId}
Request samples
application/json
{
  • "enabled": true
}
Response samples
application/json
{
  • "code": 400,
  • "message": "Required parameter is missing"
}

Delete an application by id.

Use to delete an application by id.

SecuritybearerAuth
Request
path Parameters
appId
required
string

The application id to retrieve

Responses
204

Executed successfully.

400

Bad request.

401

Unauthorized

403

Forbidden

404

The specified resource was not found

500

unexpected error

503

unexpected error

delete/api/v1/apps/{appId}
Response samples
application/json
{
  • "code": 400,
  • "message": "Required parameter is missing"
}

Regenerate an application secret.

Use to regenerate the application secret by id.

SecuritybearerAuth
Request
path Parameters
appId
required
string

The application id to retrieve

Responses
200

Regenerated successfully.

400

Bad request.

401

Unauthorized

403

Forbidden

404

The specified resource was not found

500

unexpected error

503

unexpected error

post/api/v1/apps/{appId}/secret
Response samples
application/json
{
  • "secret": "189ej2ijd92fj092k049fk0"
}