Skip to main content
POST
/
v2
/
add
/
openapi-upload
Upload an OpenAPI specification file
curl --request POST \
  --url https://context7.com/api/v2/add/openapi-upload \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: multipart/form-data' \
  --form openapiFile='@example-file' \
  --form 'libraryTitle=<string>' \
  --form 'description=<string>' \
  --form skipBenchmark=true \
  --form force=true
{
  "libraryName": "/owner/repo",
  "message": "Repository submitted successfully"
}

Authorizations

Authorization
string
header
required

Get your API key at context7.com/dashboard. Treat your API key like a password and store it securely.

Body

multipart/form-data
openapiFile
file
required

The OpenAPI specification file (.json, .yaml, or .yml)

libraryTitle
string

Custom title for the library

description
string

Description of the library

skipBenchmark
enum<string>

Set to 'true' to skip benchmark quality scoring

Available options:
true
force
enum<string>

Set to 'true' to force reprocessing

Available options:
true

Response

Library submitted successfully for processing

Response after successfully submitting a library

libraryName
string
required

The library identifier assigned (e.g., /owner/repo)

message
string
required

Human-readable success message