Skip to main content
Inference providers enable you to connect external machine learning models and services to your Avala projects. Configure API endpoints, authentication, and test connectivity to ensure smooth integration.

List inference providers

Retrieve a paginated list of inference providers.
const providers = await avala.inferenceProviders.list({
  limit: 50,
  cursor: 'next-cursor'
});

Parameters

options.limit
number
Maximum number of providers to return per page
options.cursor
string
Cursor for pagination

Returns

Returns a cursor-paginated list of inference provider objects.
items
InferenceProvider[]
Array of inference provider objects
nextCursor
string | null
Cursor for the next page of results
previousCursor
string | null
Cursor for the previous page of results
hasMore
boolean
Whether more results are available

Create an inference provider

Create a new inference provider.
const provider = await avala.inferenceProviders.create({
  name: 'YOLOv8 Detection',
  description: 'Object detection using YOLOv8',
  providerType: 'http',
  config: {
    endpoint: 'https://api.example.com/predict',
    apiKey: 'your-api-key',
    timeout: 30000
  },
  project: 'project-uid'
});

Parameters

options.name
string
required
Name of the inference provider
options.description
string
Description of the provider’s purpose
options.providerType
string
required
Type of provider (e.g., ‘http’, ‘grpc’, ‘aws’, ‘gcp’)
options.config
Record<string, unknown>
required
Configuration object containing provider-specific settings like endpoint URL, API keys, etc.
options.project
string
Project UID to scope the provider to

Returns

Returns the created inference provider object.
uid
string
Unique identifier for the provider
name
string
Name of the provider
description
string | null
Description of the provider
providerType
string | null
Type of provider
config
object | null
Configuration settings
isActive
boolean
Whether the provider is active
project
string | null
Project UID the provider is scoped to
lastTestAt
string | null
ISO 8601 timestamp of last connectivity test
lastTestSuccess
boolean | null
Whether the last test was successful
createdAt
string | null
ISO 8601 timestamp of creation
updatedAt
string | null
ISO 8601 timestamp of last update

Get an inference provider

Retrieve a specific inference provider by UID.
const provider = await avala.inferenceProviders.get('provider-uid');

Parameters

uid
string
required
The unique identifier of the inference provider

Returns

Returns the inference provider object.

Update an inference provider

Update an existing inference provider.
const provider = await avala.inferenceProviders.update('provider-uid', {
  name: 'Updated Provider Name',
  isActive: false,
  config: {
    endpoint: 'https://api.example.com/v2/predict',
    apiKey: 'new-api-key'
  }
});

Parameters

uid
string
required
The unique identifier of the provider to update
options.name
string
New name for the provider
options.description
string
New description
options.providerType
string
New provider type
options.config
Record<string, unknown>
Updated configuration settings
options.isActive
boolean
Whether the provider should be active
options.project
string
New project UID to scope the provider to

Returns

Returns the updated inference provider object.

Delete an inference provider

Delete an inference provider.
await avala.inferenceProviders.delete('provider-uid');

Parameters

uid
string
required
The unique identifier of the provider to delete

Returns

Returns void on success.

Test an inference provider

Test connectivity and configuration of an inference provider.
const result = await avala.inferenceProviders.test('provider-uid');

Parameters

uid
string
required
The unique identifier of the provider to test

Returns

success
boolean
Whether the test was successful
message
string
Description of the test result
testedAt
string
ISO 8601 timestamp of when the test was performed

Build docs developers (and LLMs) love