cURL
curl --request PUT \
--url https://my.orq.ai/v2/skills/{skill_id}/bundle \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"bundle": "<string>"
}
'import { readFile } from 'node:fs/promises';
import { Orq } from '@orq-ai/node';
const orq = new Orq({ apiKey: process.env.ORQ_API_KEY });
const result = await orq.skills.replaceBundle({
skillId: 'skill_01HZXW2K7Y8Q9M0N1P2R3S4T5V',
replaceSkillBundleRequest: {
bundle: (await readFile('skill.zip')).toString('base64'),
},
});
console.log(result);
import requests
url = "https://my.orq.ai/v2/skills/{skill_id}/bundle"
payload = { "bundle": "<string>" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text){
"skill": {
"skill_id": "<string>",
"display_name": "<string>",
"description": "<string>",
"tags": [
"<string>"
],
"project_id": "<string>",
"path": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"created_by_id": "<string>",
"updated_by_id": "<string>",
"instructions": "<string>",
"version": "<string>",
"files": [
{
"path": "<string>",
"size_bytes": "<string>",
"sha256": "<string>",
"content_type": "<string>"
}
],
"has_files": true,
"repository_source": {
"connection_id": "<string>",
"repository_url": "<string>",
"ref": "<string>",
"subdirectory": "<string>",
"commit_sha": "<string>"
},
"sharing": {
"all_projects": {},
"selected": {
"project_ids": [
"<string>"
]
},
"allow_version_pin": true,
"allow_fork": true,
"auto_grant_new_projects": true
}
}
}{
"message": "<string>",
"code": 123,
"details": [
"<unknown>"
]
}Skills
Replace a skill bundle
PUT
/
v2
/
skills
/
{skill_id}
/
bundle
cURL
curl --request PUT \
--url https://my.orq.ai/v2/skills/{skill_id}/bundle \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"bundle": "<string>"
}
'import { readFile } from 'node:fs/promises';
import { Orq } from '@orq-ai/node';
const orq = new Orq({ apiKey: process.env.ORQ_API_KEY });
const result = await orq.skills.replaceBundle({
skillId: 'skill_01HZXW2K7Y8Q9M0N1P2R3S4T5V',
replaceSkillBundleRequest: {
bundle: (await readFile('skill.zip')).toString('base64'),
},
});
console.log(result);
import requests
url = "https://my.orq.ai/v2/skills/{skill_id}/bundle"
payload = { "bundle": "<string>" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text){
"skill": {
"skill_id": "<string>",
"display_name": "<string>",
"description": "<string>",
"tags": [
"<string>"
],
"project_id": "<string>",
"path": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"created_by_id": "<string>",
"updated_by_id": "<string>",
"instructions": "<string>",
"version": "<string>",
"files": [
{
"path": "<string>",
"size_bytes": "<string>",
"sha256": "<string>",
"content_type": "<string>"
}
],
"has_files": true,
"repository_source": {
"connection_id": "<string>",
"repository_url": "<string>",
"ref": "<string>",
"subdirectory": "<string>",
"commit_sha": "<string>"
},
"sharing": {
"all_projects": {},
"selected": {
"project_ids": [
"<string>"
]
},
"allow_version_pin": true,
"allow_fork": true,
"auto_grant_new_projects": true
}
}
}{
"message": "<string>",
"code": 123,
"details": [
"<unknown>"
]
}Related guide: Skills guide. See the Skills guide for a walkthrough with examples.
Was this page helpful?