GET
/
logs
/
exports
/
{exportId}
from portkey_ai import Portkey

portkey = Portkey(
  api_key="PORTKEY_API_KEY"
)

res = portkey.logs.exports.retrieve(
  export_id="EXPORT_ID"
)

print(res)
{
  "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "organisation_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "filters": {
    "time_of_generation_min": "2023-11-07T05:31:56Z",
    "time_of_generation_max": "2023-11-07T05:31:56Z",
    "total_units_min": 123,
    "total_units_max": 123,
    "cost_min": 123,
    "cost_max": 123,
    "ai_model": "<string>",
    "prompt_token_min": 123,
    "prompt_token_max": 123,
    "completion_token_min": 123,
    "completion_token_max": 123,
    "status_code": "<string>",
    "metadata": {},
    "ai_org_model": "openai__gpt-3.5-turbo, anthropic__claude-2.1",
    "weighted_feedback_min": 123,
    "weighted_feedback_max": 123,
    "virtual_keys": "<string>",
    "trace_id": "<string>",
    "configs": "<string>",
    "workspace_slug": "<string>",
    "prompt_slug": "<string>"
  },
  "requested_data": [
    "id"
  ],
  "status": "draft",
  "description": "<string>",
  "created_at": "2023-11-07T05:31:56Z",
  "last_updated_at": "2023-11-07T05:31:56Z",
  "created_by": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "workspace_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "object": "export"
}

Authorizations

x-portkey-api-key
string
header
required

Path Parameters

exportId
string
required

Response

200 - application/json

Successful response

The response is of type object.