Run a custom model
run_custom_modelRun a user-supplied prompt against a developer-provided OpenAI-compatible or custom REST HTTPS model endpoint. Use validate_custom_model to test URL and adapter settings before sending. Returns model-generated text, model name, optional usage, and account state. Requires active trial or Pro and transmits prompt content to the selected provider. Credentials are transient, not persisted; localhost/private networks are not supported.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| model | No | Model identifier at the custom provider, when needed. | |
| apiKey | No | Transient authentication key sent to the chosen provider; never log or embed in prompts. | |
| prompt | Yes | Required nonempty prompt to send externally, maximum 30,000 characters. | |
| system | No | Optional system instructions supported by the endpoint. | |
| baseUrl | No | Required public HTTPS base URL for openai-compatible mode. | |
| authMode | No | Custom REST authentication mode, default bearer. | bearer |
| endpoint | No | Required public HTTPS inference URL for custom-rest mode. | |
| maxTokens | No | Optional maximum output token count, subject to model limits. | |
| uiLanguage | No | Interface language name or code, e.g. EN; independent of source and response languages. | EN |
| adapterMode | Yes | Adapter for the target endpoint: openai-compatible or custom-rest. | |
| promptField | No | Custom REST request JSON key for prompt content. | prompt |
| systemField | No | Custom REST request JSON key for system instructions. | system |
| temperature | No | Optional response sampling randomness between 0 and 2. | |
| apiKeyHeader | No | Custom REST API-key authentication header name. | x-api-key |
| extraHeaders | No | Extra HTTP headers required by the provider, if any. | |
| inputLanguage | No | Language name or code of input text, e.g. es; defaults to EN. | EN |
| outputLanguage | No | Requested output language name or code, e.g. fr; defaults to EN. | EN |
| responseTextPath | No | Optional JSON response field/path containing generated text. |