Overview
PUT/usage/usage-events/{id}usage

Update usage_events

Replace a record in usage-events by id.

Auth: bearerAuth — calls run as the authenticated user.

Parameters
  • idpathstring
Request body

application/json · optional

  • scopeoptionalstring
  • principalIdoptionalstring
  • ecosystemIdoptionalstring?
  • routeoptionalstring
  • methodoptionalstring
  • statusoptionalinteger
  • requestBytesoptionalinteger
  • responseBytesoptionalinteger
  • occurredAtoptionalstring
Example
{
  "scope": "string",
  "principalId": "string",
  "ecosystemId": "string",
  "route": "string",
  "method": "string",
  "status": 0,
  "requestBytes": 0,
  "responseBytes": 0,
  "occurredAt": "string"
}
Responses
200

usage_events

  • idinteger
  • scopestring
  • principalIdstring
  • ecosystemIdstring?
  • routestring
  • methodstring
  • statusinteger
  • requestBytesinteger
  • responseBytesinteger
  • occurredAtstring
Example
{
  "id": 0,
  "scope": "string",
  "principalId": "string",
  "ecosystemId": "string",
  "route": "string",
  "method": "string",
  "status": 0,
  "requestBytes": 0,
  "responseBytes": 0,
  "occurredAt": "string"
}
400

Error

  • erroroptionalobject
Example
{
  "error": {
    "message": "string",
    "code": "string"
  }
}
401

Error

  • erroroptionalobject
Example
{
  "error": {
    "message": "string",
    "code": "string"
  }
}
404

Error

  • erroroptionalobject
Example
{
  "error": {
    "message": "string",
    "code": "string"
  }
}
Code examples
cURL
curl -X PUT "https://api.agenticdeveloperhub.com/usage/usage-events/{id}" \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
  "scope": "string",
  "principalId": "string",
  "ecosystemId": "string",
  "route": "string",
  "method": "string",
  "status": 0,
  "requestBytes": 0,
  "responseBytes": 0,
  "occurredAt": "string"
}'
JavaScript
const res = await fetch("https://api.agenticdeveloperhub.com/usage/usage-events/{id}", {
  method: "PUT",
  headers: {
    "Authorization": "Bearer YOUR_TOKEN",
    "Content-Type": "application/json"
  },
  body: "{\n  \"scope\": \"string\",\n  \"principalId\": \"string\",\n  \"ecosystemId\": \"string\",\n  \"route\": \"string\",\n  \"method\": \"string\",\n  \"status\": 0,\n  \"requestBytes\": 0,\n  \"responseBytes\": 0,\n  \"occurredAt\": \"string\"\n}",
});
const data = await res.json();