Discover available models
Read the list for the current API key before configuring an application. The list reflects that key's current availability and is not a permanent catalog promise.
Request the model list
curl https://1pkapi.com/v1/models \
-H "Authorization: Bearer YOUR_API_KEY"Read model IDs from the response data[].id array and use one of those IDs in requests.
Select a model
- Use an ID returned for the same key and environment.
- Keep the model ID in configuration, not scattered through application code.
- Recheck the list after a configuration change or a model-not-available error.
Handle errors
A model list does not guarantee that every future request will succeed. Applications should handle standard API errors and avoid retry loops for an unavailable model. See error troubleshooting for the information to collect.
