API Package Specification

Get the API package current specification

Changed on

Fetches the current specification of an API Package.

get/v3/api-packages/{packageId}/current-specification

Request

  • Base URL
    https://global.api.konghq.com
  • Auth
    • HTTP bearer
    • or HTTP bearer
    • or HTTP bearer
    • or HTTP bearer

Path parameters

packageId, string uuid required
Example:9f5061ce-78f6-4452-9108-ad7c02821fd5

The UUID API Package identifier

Response

API specification (OpenAPI or AsyncAPI)

object required
id, string uuid required

The API specification identifier.

content, string required

The raw content of your API specification, in json or yaml format (OpenAPI or AsyncAPI).

validation_messages, object[] required

The errors that occurred while parsing the API specification.

type, 'oas2' | 'oas3' | 'asyncapi' required

The type of specification being stored. This allows us to render the specification correctly.

created_at, string date-time required

An ISO-8601 timestamp representation of entity creation date.

updated_at, string date-time required

An ISO-8601 timestamp representation of entity update date.

Example response

{
  "id": "7710d5c4-d902-410b-992f-18b814155b53",
  "content": "{\"openapi\":\"3.0.3\",\"info\":{\"title\":\"Example API\",\"version\":\"1.0.0\"},\"paths\":{\"/example\":{\"get\":{\"summary\":\"Example endpoint\",\"responses\":{\"200\":{\"description\":\"Successful response\"}}}}}}",
  "type": "oas3",
  "created_at": "2022-11-04T20:10:06.927Z",
  "updated_at": "2022-11-04T20:10:06.927Z"
}

Changes

    • breaking

      added to the invalid_parameters/items response property oneOf list for the response status

    • warning

      added the new key_invalid enum value to the invalid_parameters/items/oneOf[#/components/schemas/InvalidParameterStandard]/rule response property for the response status

    • warning

      added the new unique enum value to the invalid_parameters/items/oneOf[#/components/schemas/InvalidParameterStandard]/rule response property for the response status