使用说明

API User Guide

Running API User Guide and API Integration Guide

Running API provides a unified endpoint for calling AI models. In the website dashboard, you can manage API keys, view available models and pricing, and check usage records. You can also integrate the API into your own application or an OpenAI-compatible client.

1. What Do You Need Before Getting Started?

Before using the API, prepare the following:

  • Website account: Used to sign in to the dashboard and manage your balance and API keys.
  • Available balance or quota: Model usage is charged according to actual consumption and the billing rules for your group.
  • API key: Create one on the dashboard's "API Keys" page. It is used to authenticate requests.
  • Model name: Copy it from the website's model page. It must exactly match the name shown there.
  • A calling tool: An application that can send HTTP requests, a command-line tool, or an OpenAI-compatible client.

Base URL: https://www.apibenpao.com/v1
Authentication: Authorization: Bearer YOUR_API_KEY

2. How Do You Create an API Key?

  1. Sign in to Running API and open the "API Keys" page.
  2. Click Create Key and enter a recognizable name, such as "Personal Development" or "Project Testing."
  3. Configure the quota, expiration date, group, or model restrictions as needed, depending on the options available on the page.
  4. Copy the key after it is created and enter it in your application or client.

An API key is a credential for making calls. Do not share it publicly, commit it to a code repository, or place it in website frontend code that visitors can access. Use a separate key for each project. If a key is exposed, disable it immediately and create a replacement.

3. How Do You Configure an AI Client?

In a client that supports a custom OpenAI-compatible endpoint, enter the following settings:

SettingValue
API typeOpenAI-compatible API
Base URLhttps://www.apibenpao.com/v1
API KeyAn API key created in the Running API dashboard
ModelThe full model name copied from the website's model page

Some clients automatically append /v1. In that case, enter https://www.apibenpao.com as the URL. If the endpoint is reported as not found, check whether /v1 has been appended twice. Supported endpoints and parameters may vary by model; configure them according to the model's documentation.

4. How Do You Make API Calls from an Application?

The following example uses the chat completions endpoint. Replace YOUR_API_KEY with your own key, and make sure your account has access to the example model.

curl https://www.apibenpao.com/v1/chat/completions \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "gpt-6.1-sol",
    "messages": [
      {"role": "user", "content": "Hello, please introduce yourself in one sentence."}
    ],
    "stream": false
  }'

Parameter notes: model is the model name; messages contains the conversation; and stream: false means the request waits for the complete response. Enable streaming or add other parameters only when supported by both the model and the endpoint. On success, the chat text is typically found at choices[0].message.content.

5. How Do You Generate Images with AI?

After signing in, open AI Image Generation. Set the endpoint to https://www.apibenpao.com and enter an API key created on this website. Enter a prompt, upload a reference image if needed, choose the aspect ratio, resolution, and quality, then click Generate.

When generation is complete, you can download the image. Click Edit Again on a task in the history to restore its prompt and image to the input area, then submit a new task manually. Image-generation history is stored locally in the current browser and associated with the current account. It is not automatically synced if you switch computers or clear browser data.

For image generation through the API, the currently available model name is tt-image-2.5. The required request format, dimensions, reference-image handling, and response format depend on the interfaces supported by that model. The response may contain an image URL or Base64-encoded image data; do not process it as ordinary chat text.

6. How Do You Check Costs and Usage Records?

Check the model pricing page for unit prices, the balance page for your available quota, and the usage logs for request results, consumption, and charges. Prices on this website are displayed in Chinese yuan (CNY). Final charges are determined by the applicable billing rules and shown in the usage logs. Factors such as input length, output length, model, and group may affect the cost.

7. Frequently Asked Questions

IssueWhat to check
401 authentication failedCheck that the key is complete, has not expired or been disabled, and that the Bearer authorization header is formatted correctly.
403 access deniedCheck whether your account, key, group, and model permissions allow the operation.
404 endpoint not foundCheck the Base URL and request path, and make sure /v1 has not been appended twice.
429 request limitedUse the response to identify whether this is a rate limit, concurrency limit, or quota issue. If a Retry-After value is provided, wait for the specified period.
Model not found or unavailableCheck that the model name is correct and that the current group supports the model.
Insufficient balance or quotaCheck both the account balance and the API key quota. Add funds or quota before trying again.
Timeout or 5xx errorTry again later and keep the error details. Set a reasonable timeout for long-running tasks and avoid submitting the same request repeatedly.

When reporting an issue, include the time it occurred, model name, status code, error message, and request ID (if available). Do not provide your full API key, password, or sensitive business data.

目录