Guardrails uses pay-as-you-go billing. Activating the service is free — charges apply only when you make API calls or run moderation checks.
After activation, the Content Compliance check service is enabled by default. To use sensitive content detection or prompt attack detection, enable these features separately in the console.
Activate pay-as-you-go
Go to the Guardrails activation page.
Read and agree to the Terms of Service, then click Buy Now.
Activation is free. Billing starts when you use the service.
Pricing
Charges are based on the connection type, moderation type, and the volume of content checked.
Billing units
Two billing units apply depending on the connection type and model selected:
| Unit | Definition | When it applies |
|---|---|---|
| Segment | 1 segment = up to 3,000 characters. Content under 3,000 characters counts as 1 segment. | Billing is based on the total character count of the custom prompt. |
| Call | Each API request = 1 call, regardless of content length. | The selected model does not involve custom prompts. |
Which model determines the billing method
The large language model (LLM) you select determines whether you are billed per segment or per call:
| LLM | Billing method | Notes |
|---|---|---|
| Qwen3_Flash | Per segment (Basic) | Billing is based on the total character count of the custom prompt. |
| Qwen3Guard-Gen-4B | Per call (Basic) | No custom prompt involved; each call is one transaction. |
| Qwen3_Plus | Per segment (Advanced) | Billing is based on the total character count of the custom prompt. |
Price table
| Connection type | Moderation type | Service identifier | Supported services | Unit price |
|---|---|---|---|---|
| API access | Custom Detection Agent – Per Segment – Basic | text_guard_llm_standard | AI Input Content Security Check (query_security_check), AI-generated Content Security Check (response_security_check) | USD 8.00 / 10,000 segments |
API access | Custom Detection Agent - Per Call - Basic text_guard_llm_standard |
| USD 8.00 per 10,000 calls Important
| |
| API access | Custom Detection Agent – Per Segment – Advanced | text_guard_llm_advanced | AI Input Content Security Check (query_security_check), AI-generated Content Security Check (response_security_check) | USD 16.00 / 10,000 segments |
API/AI Gateway integration | Text moderation - by call - advanced text_guard_advanced |
| USD 6/10,000 calls | |
API/AI Gateway integration | Prompt attack moderation |
| USD 6/10,000 calls Important This feature will be commercially billed starting from January 22, 2026. If you do not need this service, disable it in the Guardrails console to avoid incurring fees. | |
API/AI Gateway integration | Sensitive content moderation - by call - advanced text_sddp_advanced |
| USD 6/10,000 calls |
Prompt attack moderation is commercially billed starting January 22, 2026. If you do not need this feature, disable it in the Guardrails console to avoid charges.
Billing cycle and overdue payments
Guardrails uses a 24-hour billing cycle. Bills are generated 10 to 12 hours after the end of each calendar day and deducted automatically from your Alibaba Cloud account balance.
If your account has an overdue payment, the service is paused. After you pay the overdue amount, the service resumes within 5 minutes.
Enable additional detection features
After activation, go to the Guardrails console and navigate to Protection Configuration > Configuration to enable optional detection features based on your needs.
The following features are available:
Sensitive content detection — billed separately
Prompt injection detection — billed separately
Malicious file detection
Digital watermarking
When you enable Sensitive content detection or Prompt injection detection, review the billing information in the confirmation window before proceeding.