{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/jobspipe/json-schema/jobspipe-enrich-response-schema.json",
  "title": "EnrichResponse",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/jobspipe-contacts-api-openapi.yml#/components/schemas/EnrichResponse",
  "type": "object",
  "required": [
    "results",
    "found",
    "credits_charged"
  ],
  "properties": {
    "results": {
      "type": "array",
      "items": {
        "type": "object",
        "required": [
          "index",
          "status",
          "type",
          "value",
          "credits"
        ],
        "properties": {
          "index": {
            "type": "integer",
            "description": "The item's position in the request, from 0."
          },
          "status": {
            "type": "string",
            "enum": [
              "enriched",
              "cached",
              "not_found",
              "insufficient_credits",
              "rate_limited",
              "error"
            ],
            "description": "enriched: found and charged now. cached: this account revealed it before, free. Every other status is free; insufficient_credits items were not looked up."
          },
          "type": {
            "type": "string",
            "enum": [
              "work",
              "personal",
              "phone"
            ]
          },
          "value": {
            "type": [
              "string",
              "null"
            ],
            "description": "The email or phone, or null when none was found."
          },
          "credits": {
            "type": "integer",
            "description": "Credits charged for this item."
          }
        }
      }
    },
    "found": {
      "type": "integer",
      "description": "Items with a value (enriched or cached)."
    },
    "credits_charged": {
      "type": "integer",
      "description": "Credits charged for the whole batch."
    }
  }
}