Skip to content

List Skills

skills.list(SkillListParams**kwargs) -> SyncCursorPage[Skill]
GET/skills

List Skills

ParametersExpand Collapse
after: Optional[str]

Identifier for the last item from the previous pagination request

limit: Optional[int]

Number of items to retrieve

minimum0
maximum100
order: Optional[Literal["asc", "desc"]]

Sort order of results by timestamp. Use asc for ascending order or desc for descending order.

Accepts one of the following:
"asc"
"desc"
ReturnsExpand Collapse
class Skill: …
id: str

Unique identifier for the skill.

created_at: int

Unix timestamp (seconds) for when the skill was created.

default_version: str

Default version for the skill.

description: str

Description of the skill.

latest_version: str

Latest version for the skill.

name: str

Name of the skill.

object: Literal["skill"]

The object type, which is skill.

List Skills

import os
from openai import OpenAI

client = OpenAI(
    api_key=os.environ.get("OPENAI_API_KEY"),  # This is the default and can be omitted
)
page = client.skills.list()
page = page.data[0]
print(page.id)
{
  "data": [
    {
      "id": "id",
      "created_at": 0,
      "default_version": "default_version",
      "description": "description",
      "latest_version": "latest_version",
      "name": "name",
      "object": "skill"
    }
  ],
  "first_id": "first_id",
  "has_more": true,
  "last_id": "last_id",
  "object": "list"
}
Returns Examples
{
  "data": [
    {
      "id": "id",
      "created_at": 0,
      "default_version": "default_version",
      "description": "description",
      "latest_version": "latest_version",
      "name": "name",
      "object": "skill"
    }
  ],
  "first_id": "first_id",
  "has_more": true,
  "last_id": "last_id",
  "object": "list"
}