Gestionar reglas de seguimiento
Cree, consulte, edite y elimine reglas de seguimiento. Compruebe los estados HTTP esperados y las restricciones para eliminar reglas en uso.
En esta página
- GET /public-api/v1/diff-projects/{id}/rules
- POST /public-api/v1/diff-projects/{id}/rules
- GET /public-api/v1/diff-projects/{id}/rules/expected-http-statuses
- GET /public-api/v1/diff-projects/{id}/rules/{rule_id}
- PATCH /public-api/v1/diff-projects/{id}/rules/{rule_id}
- DELETE /public-api/v1/diff-projects/{id}/rules/{rule_id}
Elija un método en el índice. Revise el método HTTP, la ruta, los permisos, los parámetros obligatorios y el cuerpo. Los bloques JSON con schema, properties y $ref describen el contrato; no se envían como cuerpo de una solicitud. Los ejemplos de solicitudes y los esquemas de respuesta están identificados por separado.
GET /public-api/v1/diff-projects/{id}/rules
Parámetros
Modelos de datos relacionados: CacheControl · RateLimitLimit · RateLimitRemaining · RateLimitResetAt · RetryAfter · XRequestID · DiffRuleListResponse · ErrorResponse · XID
id (path)
{
"required": true,
"schema": {
"$ref": "#/components/schemas/XID"
}
}
limit (query)
{
"schema": {
"type": "integer",
"minimum": 1,
"maximum": 10000,
"default": 1000
}
}
offset (query)
{
"schema": {
"type": "integer",
"minimum": 0,
"default": 0
}
}
Respuestas
200
Reglas de alertas.
{
"headers": {
"X-Request-ID": {
"$ref": "#/components/headers/XRequestID"
}
},
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/DiffRuleListResponse"
}
}
}
}
default
Sin una clave válida, las cabeceras de límites corresponden a intentos fallidos por IP. Tras la autenticación, corresponden a la clave o cuenta. Pueden faltar por un bloqueo previo o un contador no disponible. X-RateLimit-Reset es una marca de tiempo Unix en segundos; Retry-After en 429 es una espera en segundos.
{
"headers": {
"X-Request-ID": {
"$ref": "#/components/headers/XRequestID"
},
"X-RateLimit-Limit": {
"$ref": "#/components/headers/RateLimitLimit"
},
"X-RateLimit-Remaining": {
"$ref": "#/components/headers/RateLimitRemaining"
},
"X-RateLimit-Reset": {
"$ref": "#/components/headers/RateLimitResetAt"
},
"Cache-Control": {
"$ref": "#/components/headers/CacheControl"
},
"Retry-After": {
"$ref": "#/components/headers/RetryAfter"
}
},
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ErrorResponse"
}
}
}
}
POST /public-api/v1/diff-projects/{id}/rules
Parámetros
Modelos de datos relacionados: CacheControl · RateLimitLimit · RateLimitRemaining · RateLimitResetAt · RetryAfter · XRequestID · DiffRuleResponse · DiffRuleWriteRequest · ErrorResponse · XID
id (path)
{
"required": true,
"schema": {
"$ref": "#/components/schemas/XID"
}
}
Solicitud
{
"required": true,
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/DiffRuleWriteRequest"
}
}
}
}
Respuestas
201
Regla de alertas.
{
"headers": {
"X-Request-ID": {
"$ref": "#/components/headers/XRequestID"
}
},
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/DiffRuleResponse"
}
}
}
}
default
{
"headers": {
"X-Request-ID": {
"$ref": "#/components/headers/XRequestID"
},
"X-RateLimit-Limit": {
"$ref": "#/components/headers/RateLimitLimit"
},
"X-RateLimit-Remaining": {
"$ref": "#/components/headers/RateLimitRemaining"
},
"X-RateLimit-Reset": {
"$ref": "#/components/headers/RateLimitResetAt"
},
"Cache-Control": {
"$ref": "#/components/headers/CacheControl"
},
"Retry-After": {
"$ref": "#/components/headers/RetryAfter"
}
},
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ErrorResponse"
}
}
}
}
GET /public-api/v1/diff-projects/{id}/rules/expected-http-statuses
Parámetros
Modelos de datos relacionados: CacheControl · RateLimitLimit · RateLimitRemaining · RateLimitResetAt · RetryAfter · XRequestID · DiffRuleExpectedHTTPStatusesResponse · ErrorResponse · XID
id (path)
{
"required": true,
"schema": {
"$ref": "#/components/schemas/XID"
}
}
Respuestas
200
Estados HTTP esperados.
{
"headers": {
"X-Request-ID": {
"$ref": "#/components/headers/XRequestID"
}
},
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/DiffRuleExpectedHTTPStatusesResponse"
}
}
}
}
default
{
"headers": {
"X-Request-ID": {
"$ref": "#/components/headers/XRequestID"
},
"X-RateLimit-Limit": {
"$ref": "#/components/headers/RateLimitLimit"
},
"X-RateLimit-Remaining": {
"$ref": "#/components/headers/RateLimitRemaining"
},
"X-RateLimit-Reset": {
"$ref": "#/components/headers/RateLimitResetAt"
},
"Cache-Control": {
"$ref": "#/components/headers/CacheControl"
},
"Retry-After": {
"$ref": "#/components/headers/RetryAfter"
}
},
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ErrorResponse"
}
}
}
}
GET /public-api/v1/diff-projects/{id}/rules/{rule_id}
Parámetros
Modelos de datos relacionados: CacheControl · RateLimitLimit · RateLimitRemaining · RateLimitResetAt · RetryAfter · XRequestID · DiffRuleResponse · ErrorResponse · XID
id (path)
{
"required": true,
"schema": {
"$ref": "#/components/schemas/XID"
}
}
rule_id (path)
{
"required": true,
"schema": {
"$ref": "#/components/schemas/XID"
}
}
Respuestas
200
Regla de alertas.
{
"headers": {
"X-Request-ID": {
"$ref": "#/components/headers/XRequestID"
}
},
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/DiffRuleResponse"
}
}
}
}
default
{
"headers": {
"X-Request-ID": {
"$ref": "#/components/headers/XRequestID"
},
"X-RateLimit-Limit": {
"$ref": "#/components/headers/RateLimitLimit"
},
"X-RateLimit-Remaining": {
"$ref": "#/components/headers/RateLimitRemaining"
},
"X-RateLimit-Reset": {
"$ref": "#/components/headers/RateLimitResetAt"
},
"Cache-Control": {
"$ref": "#/components/headers/CacheControl"
},
"Retry-After": {
"$ref": "#/components/headers/RetryAfter"
}
},
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ErrorResponse"
}
}
}
}
PATCH /public-api/v1/diff-projects/{id}/rules/{rule_id}
Parámetros
Modelos de datos relacionados: CacheControl · RateLimitLimit · RateLimitRemaining · RateLimitResetAt · RetryAfter · XRequestID · DiffRuleResponse · DiffRuleWriteRequest · ErrorResponse · XID
id (path)
{
"required": true,
"schema": {
"$ref": "#/components/schemas/XID"
}
}
rule_id (path)
{
"required": true,
"schema": {
"$ref": "#/components/schemas/XID"
}
}
Solicitud
{
"required": true,
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/DiffRuleWriteRequest"
}
}
}
}
Respuestas
200
Regla de alertas.
{
"headers": {
"X-Request-ID": {
"$ref": "#/components/headers/XRequestID"
}
},
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/DiffRuleResponse"
}
}
}
}
default
{
"headers": {
"X-Request-ID": {
"$ref": "#/components/headers/XRequestID"
},
"X-RateLimit-Limit": {
"$ref": "#/components/headers/RateLimitLimit"
},
"X-RateLimit-Remaining": {
"$ref": "#/components/headers/RateLimitRemaining"
},
"X-RateLimit-Reset": {
"$ref": "#/components/headers/RateLimitResetAt"
},
"Cache-Control": {
"$ref": "#/components/headers/CacheControl"
},
"Retry-After": {
"$ref": "#/components/headers/RetryAfter"
}
},
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ErrorResponse"
}
}
}
}
DELETE /public-api/v1/diff-projects/{id}/rules/{rule_id}
Parámetros
Modelos de datos relacionados: CacheControl · RateLimitLimit · RateLimitRemaining · RateLimitResetAt · RetryAfter · XRequestID · ErrorResponse · XID
id (path)
{
"required": true,
"schema": {
"$ref": "#/components/schemas/XID"
}
}
rule_id (path)
{
"required": true,
"schema": {
"$ref": "#/components/schemas/XID"
}
}
Respuestas
204
Eliminado. El cuerpo de la respuesta está vacío.
{
"headers": {
"X-Request-ID": {
"$ref": "#/components/headers/XRequestID"
}
}
}
default
{
"headers": {
"X-Request-ID": {
"$ref": "#/components/headers/XRequestID"
},
"X-RateLimit-Limit": {
"$ref": "#/components/headers/RateLimitLimit"
},
"X-RateLimit-Remaining": {
"$ref": "#/components/headers/RateLimitRemaining"
},
"X-RateLimit-Reset": {
"$ref": "#/components/headers/RateLimitResetAt"
},
"Cache-Control": {
"$ref": "#/components/headers/CacheControl"
},
"Retry-After": {
"$ref": "#/components/headers/RetryAfter"
}
},
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/ErrorResponse"
}
}
}
}
