feat(05-04): extend Tier 1 provider verify specs
- 12 Tier 1 providers now carry success_codes, failure_codes, rate_limit_codes
- {{KEY}} template in headers or URL (double-brace canonical form)
- metadata_paths added where provider APIs return useful metadata
- Anthropic switched to POST /v1/messages with minimal body
- Perplexity gains JSON body, content-type header
- Inflection verify URL left empty (no public endpoint)
- Dual-location sync preserved: providers/ mirrors pkg/providers/definitions/
This commit is contained in:
@@ -17,6 +17,7 @@ verify:
|
|||||||
method: GET
|
method: GET
|
||||||
url: https://api.ai21.com/studio/v1/models
|
url: https://api.ai21.com/studio/v1/models
|
||||||
headers:
|
headers:
|
||||||
Authorization: "Bearer {KEY}"
|
Authorization: "Bearer {{KEY}}"
|
||||||
valid_status: [200]
|
success_codes: [200]
|
||||||
invalid_status: [401, 403]
|
failure_codes: [401, 403]
|
||||||
|
rate_limit_codes: [429]
|
||||||
|
|||||||
@@ -15,10 +15,16 @@ patterns:
|
|||||||
entropy_min: 3.5
|
entropy_min: 3.5
|
||||||
confidence: high
|
confidence: high
|
||||||
verify:
|
verify:
|
||||||
method: GET
|
method: POST
|
||||||
url: https://api.anthropic.com/v1/models
|
url: https://api.anthropic.com/v1/messages
|
||||||
headers:
|
headers:
|
||||||
x-api-key: "{KEY}"
|
x-api-key: "{{KEY}}"
|
||||||
anthropic-version: "2023-06-01"
|
anthropic-version: "2023-06-01"
|
||||||
valid_status: [200]
|
content-type: "application/json"
|
||||||
invalid_status: [401, 403]
|
body: '{"model":"claude-haiku-4-5","max_tokens":1,"messages":[{"role":"user","content":"hi"}]}'
|
||||||
|
success_codes: [200]
|
||||||
|
failure_codes: [401, 403]
|
||||||
|
rate_limit_codes: [429, 529]
|
||||||
|
metadata_paths:
|
||||||
|
model: "model"
|
||||||
|
stop_reason: "stop_reason"
|
||||||
|
|||||||
@@ -17,6 +17,9 @@ verify:
|
|||||||
method: GET
|
method: GET
|
||||||
url: https://api.cohere.ai/v1/models
|
url: https://api.cohere.ai/v1/models
|
||||||
headers:
|
headers:
|
||||||
Authorization: "Bearer {KEY}"
|
Authorization: "Bearer {{KEY}}"
|
||||||
valid_status: [200]
|
success_codes: [200]
|
||||||
invalid_status: [401, 403]
|
failure_codes: [401, 403]
|
||||||
|
rate_limit_codes: [429]
|
||||||
|
metadata_paths:
|
||||||
|
first_model: "models.0.name"
|
||||||
|
|||||||
@@ -17,6 +17,9 @@ verify:
|
|||||||
method: GET
|
method: GET
|
||||||
url: https://api.deepseek.com/v1/models
|
url: https://api.deepseek.com/v1/models
|
||||||
headers:
|
headers:
|
||||||
Authorization: "Bearer {KEY}"
|
Authorization: "Bearer {{KEY}}"
|
||||||
valid_status: [200]
|
success_codes: [200]
|
||||||
invalid_status: [401, 403]
|
failure_codes: [401, 403]
|
||||||
|
rate_limit_codes: [429]
|
||||||
|
metadata_paths:
|
||||||
|
first_model: "data.0.id"
|
||||||
|
|||||||
@@ -14,7 +14,9 @@ patterns:
|
|||||||
confidence: high
|
confidence: high
|
||||||
verify:
|
verify:
|
||||||
method: GET
|
method: GET
|
||||||
url: https://generativelanguage.googleapis.com/v1/models?key={KEY}
|
url: https://generativelanguage.googleapis.com/v1/models?key={{KEY}}
|
||||||
headers: {}
|
success_codes: [200]
|
||||||
valid_status: [200]
|
failure_codes: [400, 401, 403]
|
||||||
invalid_status: [400, 401, 403]
|
rate_limit_codes: [429]
|
||||||
|
metadata_paths:
|
||||||
|
first_model: "models.0.name"
|
||||||
|
|||||||
@@ -16,6 +16,9 @@ verify:
|
|||||||
method: GET
|
method: GET
|
||||||
url: https://api.groq.com/openai/v1/models
|
url: https://api.groq.com/openai/v1/models
|
||||||
headers:
|
headers:
|
||||||
Authorization: "Bearer {KEY}"
|
Authorization: "Bearer {{KEY}}"
|
||||||
valid_status: [200]
|
success_codes: [200]
|
||||||
invalid_status: [401, 403]
|
failure_codes: [401, 403]
|
||||||
|
rate_limit_codes: [429]
|
||||||
|
metadata_paths:
|
||||||
|
first_model: "data.0.id"
|
||||||
|
|||||||
@@ -16,6 +16,6 @@ patterns:
|
|||||||
verify:
|
verify:
|
||||||
method: GET
|
method: GET
|
||||||
url: ""
|
url: ""
|
||||||
headers: {}
|
success_codes: [200]
|
||||||
valid_status: []
|
failure_codes: [401, 403]
|
||||||
invalid_status: []
|
rate_limit_codes: [429]
|
||||||
|
|||||||
@@ -17,6 +17,9 @@ verify:
|
|||||||
method: GET
|
method: GET
|
||||||
url: https://api.mistral.ai/v1/models
|
url: https://api.mistral.ai/v1/models
|
||||||
headers:
|
headers:
|
||||||
Authorization: "Bearer {KEY}"
|
Authorization: "Bearer {{KEY}}"
|
||||||
valid_status: [200]
|
success_codes: [200]
|
||||||
invalid_status: [401, 403]
|
failure_codes: [401, 403]
|
||||||
|
rate_limit_codes: [429]
|
||||||
|
metadata_paths:
|
||||||
|
first_model: "data.0.id"
|
||||||
|
|||||||
@@ -23,6 +23,10 @@ verify:
|
|||||||
method: GET
|
method: GET
|
||||||
url: https://api.openai.com/v1/models
|
url: https://api.openai.com/v1/models
|
||||||
headers:
|
headers:
|
||||||
Authorization: "Bearer {KEY}"
|
Authorization: "Bearer {{KEY}}"
|
||||||
valid_status: [200]
|
success_codes: [200]
|
||||||
invalid_status: [401, 403]
|
failure_codes: [401, 403]
|
||||||
|
rate_limit_codes: [429]
|
||||||
|
metadata_paths:
|
||||||
|
first_model: "data.0.id"
|
||||||
|
object_type: "object"
|
||||||
|
|||||||
@@ -16,6 +16,9 @@ verify:
|
|||||||
method: POST
|
method: POST
|
||||||
url: https://api.perplexity.ai/chat/completions
|
url: https://api.perplexity.ai/chat/completions
|
||||||
headers:
|
headers:
|
||||||
Authorization: "Bearer {KEY}"
|
Authorization: "Bearer {{KEY}}"
|
||||||
valid_status: [200, 400]
|
content-type: "application/json"
|
||||||
invalid_status: [401, 403]
|
body: '{"model":"sonar","messages":[{"role":"user","content":"hi"}],"max_tokens":1}'
|
||||||
|
success_codes: [200]
|
||||||
|
failure_codes: [401, 403]
|
||||||
|
rate_limit_codes: [429]
|
||||||
|
|||||||
@@ -17,6 +17,9 @@ verify:
|
|||||||
method: GET
|
method: GET
|
||||||
url: https://api.together.xyz/v1/models
|
url: https://api.together.xyz/v1/models
|
||||||
headers:
|
headers:
|
||||||
Authorization: "Bearer {KEY}"
|
Authorization: "Bearer {{KEY}}"
|
||||||
valid_status: [200]
|
success_codes: [200]
|
||||||
invalid_status: [401, 403]
|
failure_codes: [401, 403]
|
||||||
|
rate_limit_codes: [429]
|
||||||
|
metadata_paths:
|
||||||
|
first_model: "0.id"
|
||||||
|
|||||||
@@ -15,6 +15,10 @@ verify:
|
|||||||
method: GET
|
method: GET
|
||||||
url: https://api.x.ai/v1/api-key
|
url: https://api.x.ai/v1/api-key
|
||||||
headers:
|
headers:
|
||||||
Authorization: "Bearer {KEY}"
|
Authorization: "Bearer {{KEY}}"
|
||||||
valid_status: [200]
|
success_codes: [200]
|
||||||
invalid_status: [401, 403]
|
failure_codes: [401, 403]
|
||||||
|
rate_limit_codes: [429]
|
||||||
|
metadata_paths:
|
||||||
|
name: "name"
|
||||||
|
acls: "acls"
|
||||||
|
|||||||
@@ -17,6 +17,7 @@ verify:
|
|||||||
method: GET
|
method: GET
|
||||||
url: https://api.ai21.com/studio/v1/models
|
url: https://api.ai21.com/studio/v1/models
|
||||||
headers:
|
headers:
|
||||||
Authorization: "Bearer {KEY}"
|
Authorization: "Bearer {{KEY}}"
|
||||||
valid_status: [200]
|
success_codes: [200]
|
||||||
invalid_status: [401, 403]
|
failure_codes: [401, 403]
|
||||||
|
rate_limit_codes: [429]
|
||||||
|
|||||||
@@ -15,10 +15,16 @@ patterns:
|
|||||||
entropy_min: 3.5
|
entropy_min: 3.5
|
||||||
confidence: high
|
confidence: high
|
||||||
verify:
|
verify:
|
||||||
method: GET
|
method: POST
|
||||||
url: https://api.anthropic.com/v1/models
|
url: https://api.anthropic.com/v1/messages
|
||||||
headers:
|
headers:
|
||||||
x-api-key: "{KEY}"
|
x-api-key: "{{KEY}}"
|
||||||
anthropic-version: "2023-06-01"
|
anthropic-version: "2023-06-01"
|
||||||
valid_status: [200]
|
content-type: "application/json"
|
||||||
invalid_status: [401, 403]
|
body: '{"model":"claude-haiku-4-5","max_tokens":1,"messages":[{"role":"user","content":"hi"}]}'
|
||||||
|
success_codes: [200]
|
||||||
|
failure_codes: [401, 403]
|
||||||
|
rate_limit_codes: [429, 529]
|
||||||
|
metadata_paths:
|
||||||
|
model: "model"
|
||||||
|
stop_reason: "stop_reason"
|
||||||
|
|||||||
@@ -17,6 +17,9 @@ verify:
|
|||||||
method: GET
|
method: GET
|
||||||
url: https://api.cohere.ai/v1/models
|
url: https://api.cohere.ai/v1/models
|
||||||
headers:
|
headers:
|
||||||
Authorization: "Bearer {KEY}"
|
Authorization: "Bearer {{KEY}}"
|
||||||
valid_status: [200]
|
success_codes: [200]
|
||||||
invalid_status: [401, 403]
|
failure_codes: [401, 403]
|
||||||
|
rate_limit_codes: [429]
|
||||||
|
metadata_paths:
|
||||||
|
first_model: "models.0.name"
|
||||||
|
|||||||
@@ -17,6 +17,9 @@ verify:
|
|||||||
method: GET
|
method: GET
|
||||||
url: https://api.deepseek.com/v1/models
|
url: https://api.deepseek.com/v1/models
|
||||||
headers:
|
headers:
|
||||||
Authorization: "Bearer {KEY}"
|
Authorization: "Bearer {{KEY}}"
|
||||||
valid_status: [200]
|
success_codes: [200]
|
||||||
invalid_status: [401, 403]
|
failure_codes: [401, 403]
|
||||||
|
rate_limit_codes: [429]
|
||||||
|
metadata_paths:
|
||||||
|
first_model: "data.0.id"
|
||||||
|
|||||||
@@ -14,7 +14,9 @@ patterns:
|
|||||||
confidence: high
|
confidence: high
|
||||||
verify:
|
verify:
|
||||||
method: GET
|
method: GET
|
||||||
url: https://generativelanguage.googleapis.com/v1/models?key={KEY}
|
url: https://generativelanguage.googleapis.com/v1/models?key={{KEY}}
|
||||||
headers: {}
|
success_codes: [200]
|
||||||
valid_status: [200]
|
failure_codes: [400, 401, 403]
|
||||||
invalid_status: [400, 401, 403]
|
rate_limit_codes: [429]
|
||||||
|
metadata_paths:
|
||||||
|
first_model: "models.0.name"
|
||||||
|
|||||||
@@ -16,6 +16,9 @@ verify:
|
|||||||
method: GET
|
method: GET
|
||||||
url: https://api.groq.com/openai/v1/models
|
url: https://api.groq.com/openai/v1/models
|
||||||
headers:
|
headers:
|
||||||
Authorization: "Bearer {KEY}"
|
Authorization: "Bearer {{KEY}}"
|
||||||
valid_status: [200]
|
success_codes: [200]
|
||||||
invalid_status: [401, 403]
|
failure_codes: [401, 403]
|
||||||
|
rate_limit_codes: [429]
|
||||||
|
metadata_paths:
|
||||||
|
first_model: "data.0.id"
|
||||||
|
|||||||
@@ -16,6 +16,6 @@ patterns:
|
|||||||
verify:
|
verify:
|
||||||
method: GET
|
method: GET
|
||||||
url: ""
|
url: ""
|
||||||
headers: {}
|
success_codes: [200]
|
||||||
valid_status: []
|
failure_codes: [401, 403]
|
||||||
invalid_status: []
|
rate_limit_codes: [429]
|
||||||
|
|||||||
@@ -17,6 +17,9 @@ verify:
|
|||||||
method: GET
|
method: GET
|
||||||
url: https://api.mistral.ai/v1/models
|
url: https://api.mistral.ai/v1/models
|
||||||
headers:
|
headers:
|
||||||
Authorization: "Bearer {KEY}"
|
Authorization: "Bearer {{KEY}}"
|
||||||
valid_status: [200]
|
success_codes: [200]
|
||||||
invalid_status: [401, 403]
|
failure_codes: [401, 403]
|
||||||
|
rate_limit_codes: [429]
|
||||||
|
metadata_paths:
|
||||||
|
first_model: "data.0.id"
|
||||||
|
|||||||
@@ -23,6 +23,10 @@ verify:
|
|||||||
method: GET
|
method: GET
|
||||||
url: https://api.openai.com/v1/models
|
url: https://api.openai.com/v1/models
|
||||||
headers:
|
headers:
|
||||||
Authorization: "Bearer {KEY}"
|
Authorization: "Bearer {{KEY}}"
|
||||||
valid_status: [200]
|
success_codes: [200]
|
||||||
invalid_status: [401, 403]
|
failure_codes: [401, 403]
|
||||||
|
rate_limit_codes: [429]
|
||||||
|
metadata_paths:
|
||||||
|
first_model: "data.0.id"
|
||||||
|
object_type: "object"
|
||||||
|
|||||||
@@ -16,6 +16,9 @@ verify:
|
|||||||
method: POST
|
method: POST
|
||||||
url: https://api.perplexity.ai/chat/completions
|
url: https://api.perplexity.ai/chat/completions
|
||||||
headers:
|
headers:
|
||||||
Authorization: "Bearer {KEY}"
|
Authorization: "Bearer {{KEY}}"
|
||||||
valid_status: [200, 400]
|
content-type: "application/json"
|
||||||
invalid_status: [401, 403]
|
body: '{"model":"sonar","messages":[{"role":"user","content":"hi"}],"max_tokens":1}'
|
||||||
|
success_codes: [200]
|
||||||
|
failure_codes: [401, 403]
|
||||||
|
rate_limit_codes: [429]
|
||||||
|
|||||||
@@ -17,6 +17,9 @@ verify:
|
|||||||
method: GET
|
method: GET
|
||||||
url: https://api.together.xyz/v1/models
|
url: https://api.together.xyz/v1/models
|
||||||
headers:
|
headers:
|
||||||
Authorization: "Bearer {KEY}"
|
Authorization: "Bearer {{KEY}}"
|
||||||
valid_status: [200]
|
success_codes: [200]
|
||||||
invalid_status: [401, 403]
|
failure_codes: [401, 403]
|
||||||
|
rate_limit_codes: [429]
|
||||||
|
metadata_paths:
|
||||||
|
first_model: "0.id"
|
||||||
|
|||||||
@@ -15,6 +15,10 @@ verify:
|
|||||||
method: GET
|
method: GET
|
||||||
url: https://api.x.ai/v1/api-key
|
url: https://api.x.ai/v1/api-key
|
||||||
headers:
|
headers:
|
||||||
Authorization: "Bearer {KEY}"
|
Authorization: "Bearer {{KEY}}"
|
||||||
valid_status: [200]
|
success_codes: [200]
|
||||||
invalid_status: [401, 403]
|
failure_codes: [401, 403]
|
||||||
|
rate_limit_codes: [429]
|
||||||
|
metadata_paths:
|
||||||
|
name: "name"
|
||||||
|
acls: "acls"
|
||||||
|
|||||||
Reference in New Issue
Block a user