Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
244 changes: 165 additions & 79 deletions specification/DigitalOcean-public.v2.yaml

Large diffs are not rendered by default.

609 changes: 592 additions & 17 deletions specification/resources/gen-ai/definitions.yml

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,14 @@ source: |-
{
"bucket_name": "test-public-gen-ai",
"bucket_region": "tor1"
},
{
"web_crawler_data_source": {
"base_url": "https://faas-blr1-8177d592.doserverless.co/api/v1/web/fn-a8217bc8-d09f-4751-8686-76c0974bf8cc/default/html-tester",
"crawling_option": "SCOPED",
"embed_media": false,
"exclude_tags":["footer", "title", "h1"]
}
}
],
"region": "tor1",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,15 @@
lang: cURL
source: |-
curl -X DELETE \
curl -X POST \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $DIGITALOCEAN_TOKEN" \
"https://api.digitalocean.com/v2/gen-ai/knowledge_bases/9a6e3975-b0c6-11ef-bf8f-4e013e2ddde4/data_sources/bd2a2db5-b8b0-11ef-bf8f-4e013e2ddde4"
"https://api.digitalocean.com/v2/gen-ai/knowledge_bases/20cd8434-6ea1-11f0-bf8f-4e013e2ddde4/data_sources" \
-d '{
"knowledge_base_uuid": "20cd8434-6ea1-11f0-bf8f-4e013e2ddde4",
"web_crawler_data_source": {
"base_url": "https://faas-blr1-8177d592.doserverless.co/api/v1/web/fn-a8217bc8-d09f-4751-8686-76c0974bf8cc/default/html-tester",
"crawling_option": "SCOPED",
"embed_media": false,
"exclude_tags": ["h1", "section"]
}
}'
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
lang: cURL
source: |-
curl -X GET \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $DIGITALOCEAN_TOKEN" \
"https://api.digitalocean.com/v2/gen-ai/agent-workspaces/agentWorkspace/agent-deployments/production"
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
description: To obtain the refresh token, needed for creation of data sources, send
a GET request to `/v2/gen-ai/oauth2/google/tokens`. Pass the code you obtrained
from the oauth flow in the field 'code'
operationId: genai_create_oauth2_google_tokens
requestBody:
content:
application/json:
schema:
$ref: ./definitions.yml#/apiGoogleOauth2GetTokensInput
responses:
"200":
content:
application/json:
schema:
$ref: ./definitions.yml#/apiGoogleOauth2GetTokensOutput
description: A successful response.
headers:
ratelimit-limit:
$ref: ../../shared/headers.yml#/ratelimit-limit
ratelimit-remaining:
$ref: ../../shared/headers.yml#/ratelimit-remaining
ratelimit-reset:
$ref: ../../shared/headers.yml#/ratelimit-reset
"401":
$ref: ../../shared/responses/unauthorized.yml
"404":
$ref: ../../shared/responses/not_found.yml
"429":
$ref: ../../shared/responses/too_many_requests.yml
"500":
$ref: ../../shared/responses/server_error.yml
default:
$ref: ../../shared/responses/unexpected_error.yml
security:
- bearer_auth:
- genai:create
summary: Get Oauth2 Google Tokens
tags:
- GradientAI Platform
x-codeSamples:
- $ref: examples/curl/genai_create_oauth2_google_tokens.yml
39 changes: 39 additions & 0 deletions specification/resources/gen-ai/genai_create_scheduled_indexing.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
description: Create Scheduled Indexing for knoweldge base
operationId: genai_create_scheduled_indexing
requestBody:
content:
application/json:
schema:
$ref: ./definitions.yml#/apiCreateScheduledIndexingInput
responses:
"200":
content:
application/json:
schema:
$ref: ./definitions.yml#/apiCreateScheduledIndexingOutput
description: A successful response.
headers:
ratelimit-limit:
$ref: ../../shared/headers.yml#/ratelimit-limit
ratelimit-remaining:
$ref: ../../shared/headers.yml#/ratelimit-remaining
ratelimit-reset:
$ref: ../../shared/headers.yml#/ratelimit-reset
"401":
$ref: ../../shared/responses/unauthorized.yml
"404":
$ref: ../../shared/responses/not_found.yml
"429":
$ref: ../../shared/responses/too_many_requests.yml
"500":
$ref: ../../shared/responses/server_error.yml
default:
$ref: ../../shared/responses/unexpected_error.yml
security:
- bearer_auth:
- genai:create
summary: Create Scheduled Indexing
tags:
- GradientAI Platform
x-codeSamples:
- $ref: examples/curl/genai_create_scheduled_indexing.yml
39 changes: 39 additions & 0 deletions specification/resources/gen-ai/genai_create_traces.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
description: To create traces, send a POST request to `/v2/gen-ai/traces`.
operationId: genai_create_traces
requestBody:
content:
application/json:
schema:
$ref: ./definitions.yml#/apiCreateTracesInputPublic
responses:
"200":
content:
application/json:
schema:
$ref: ./definitions.yml#/apiCreateTracesOutput
description: A successful response.
headers:
ratelimit-limit:
$ref: ../../shared/headers.yml#/ratelimit-limit
ratelimit-remaining:
$ref: ../../shared/headers.yml#/ratelimit-remaining
ratelimit-reset:
$ref: ../../shared/headers.yml#/ratelimit-reset
"401":
$ref: ../../shared/responses/unauthorized.yml
"404":
$ref: ../../shared/responses/not_found.yml
"429":
$ref: ../../shared/responses/too_many_requests.yml
"500":
$ref: ../../shared/responses/server_error.yml
default:
$ref: ../../shared/responses/unexpected_error.yml
security:
- bearer_auth:
- genai:create
summary: Create Traces
tags:
- GradientAI Platform
x-codeSamples:
- $ref: examples/curl/genai_create_traces.yml
77 changes: 77 additions & 0 deletions specification/resources/gen-ai/genai_delete_scheduled_indexing.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@
description: Delete Scheduled Indexing
operationId: genai_delete_scheduled_indexing
parameters:
- description: UUID of the scheduled indexing
example: '"123e4567-e89b-12d3-a456-426614174000"'
in: path
name: uuid
required: true
schema:
type: string
- example: '"example string"'
in: query
name: audit_header.actor_id
schema:
type: string
- example: '"123e4567-e89b-12d3-a456-426614174000"'
in: query
name: audit_header.actor_uuid
schema:
type: string
- example: '"example string"'
in: query
name: audit_header.user_id
schema:
type: string
- example: '"123e4567-e89b-12d3-a456-426614174000"'
in: query
name: audit_header.user_uuid
schema:
type: string
- example: '"example string"'
in: query
name: audit_header.context_urn
schema:
type: string
- example: '"example string"'
in: query
name: audit_header.actor_ip
schema:
type: string
- example: '"example string"'
in: query
name: audit_header.origin_application
schema:
type: string
responses:
"200":
content:
application/json:
schema:
$ref: ./definitions.yml#/apiDeleteScheduledIndexingOutput
description: A successful response.
headers:
ratelimit-limit:
$ref: ../../shared/headers.yml#/ratelimit-limit
ratelimit-remaining:
$ref: ../../shared/headers.yml#/ratelimit-remaining
ratelimit-reset:
$ref: ../../shared/headers.yml#/ratelimit-reset
"401":
$ref: ../../shared/responses/unauthorized.yml
"404":
$ref: ../../shared/responses/not_found.yml
"429":
$ref: ../../shared/responses/too_many_requests.yml
"500":
$ref: ../../shared/responses/server_error.yml
default:
$ref: ../../shared/responses/unexpected_error.yml
security:
- bearer_auth:
- genai:delete
summary: Delete Scheduled Indexing
tags:
- GradientAI Platform
x-codeSamples:
- $ref: examples/curl/genai_delete_scheduled_indexing.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
description: To retrieve details of a agent workspace deployment, GET request to `/v2/gen-ai/agent-workspaces/{agent_workspace_name}/agent-deployments/{agent_deployment_name}`.
The response body is a JSON object containing the agent workspace deployment
operationId: genai_get_agent_workspace_deployment
parameters:
- description: Unique agent workspace name
example: '"example string"'
in: path
name: agent_workspace_name
required: true
schema:
type: string
- description: The name of the deployment
example: '"example string"'
in: path
name: agent_deployment_name
required: true
schema:
type: string
responses:
"200":
content:
application/json:
schema:
$ref: ./definitions.yml#/apiGetAgentWorkspaceDeploymentOutput
description: A successful response.
headers:
ratelimit-limit:
$ref: ../../shared/headers.yml#/ratelimit-limit
ratelimit-remaining:
$ref: ../../shared/headers.yml#/ratelimit-remaining
ratelimit-reset:
$ref: ../../shared/headers.yml#/ratelimit-reset
"401":
$ref: ../../shared/responses/unauthorized.yml
"404":
$ref: ../../shared/responses/not_found.yml
"429":
$ref: ../../shared/responses/too_many_requests.yml
"500":
$ref: ../../shared/responses/server_error.yml
default:
$ref: ../../shared/responses/unexpected_error.yml
security:
- bearer_auth:
- genai:read
summary: Retrieve an Existing Agent Workspace Deployment
tags:
- GradientAI Platform
x-codeSamples:
- $ref: examples/curl/genai_get_agent_workspace_deployment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
description: To get a signed URL for indexing job details, send a GET request to `/v2/gen-ai/indexing_jobs/{uuid}/details_signed_url`.
operationId: genai_get_indexing_job_details_signed_url
parameters:
- description: The uuid of the indexing job
example: '"123e4567-e89b-12d3-a456-426614174000"'
in: path
name: indexing_job_uuid
required: true
schema:
type: string
responses:
"200":
content:
application/json:
schema:
$ref: ./definitions.yml#/apiGetIndexingJobDetailsSignedURLOutput
description: A successful response.
headers:
ratelimit-limit:
$ref: ../../shared/headers.yml#/ratelimit-limit
ratelimit-remaining:
$ref: ../../shared/headers.yml#/ratelimit-remaining
ratelimit-reset:
$ref: ../../shared/headers.yml#/ratelimit-reset
"401":
$ref: ../../shared/responses/unauthorized.yml
"404":
$ref: ../../shared/responses/not_found.yml
"429":
$ref: ../../shared/responses/too_many_requests.yml
"500":
$ref: ../../shared/responses/server_error.yml
default:
$ref: ../../shared/responses/unexpected_error.yml
security:
- bearer_auth:
- genai:read
summary: Get Signed URL for Indexing Job Details
tags:
- GradientAI Platform
x-codeSamples:
- $ref: examples/curl/genai_get_indexing_job_details_signed_url.yml
Loading
Loading