{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/groundmail-dev/json-schema/groundmail-dev-list-test-inbox-emails-response-schema.json",
  "title": "ListTestInboxEmailsResponse",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/groundmail-dev-test-inbox-api-openapi.yml#/components/schemas/ListTestInboxEmailsResponse",
  "type": "object",
  "required": [
    "emails",
    "has_more",
    "next_cursor"
  ],
  "properties": {
    "emails": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/TestInboxEmail"
      }
    },
    "has_more": {
      "type": "boolean"
    },
    "next_cursor": {
      "type": [
        "string",
        "null"
      ]
    }
  },
  "$defs": {
    "TestInboxEmail": {
      "type": "object",
      "required": [
        "object",
        "id",
        "source",
        "email_id",
        "from",
        "to",
        "cc",
        "subject",
        "code",
        "links",
        "received_at",
        "expires_at"
      ],
      "properties": {
        "object": {
          "type": "string",
          "enum": [
            "test_inbox_email"
          ]
        },
        "id": {
          "type": "string"
        },
        "source": {
          "type": "string",
          "enum": [
            "inbound",
            "test_key"
          ],
          "description": "`inbound`: received at your test domain (from any provider). `test_key`: sent through Groundmail with a `gm_test_` key.\n"
        },
        "email_id": {
          "type": [
            "string",
            "null"
          ],
          "description": "With `test_key`, the sent email's id (see GET /emails/{id})."
        },
        "from": {
          "type": "string"
        },
        "to": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "cc": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "subject": {
          "type": "string"
        },
        "code": {
          "type": [
            "string",
            "null"
          ],
          "description": "The one-time code found in the email (4 to 8 digits), preferring one next to words like \"code\" or \"verification\". Null when there is none.\n"
        },
        "links": {
          "type": "array",
          "description": "http(s) links in the email, in order, without duplicates.",
          "items": {
            "type": "string"
          }
        },
        "received_at": {
          "type": "string",
          "format": "date-time"
        },
        "expires_at": {
          "type": "string",
          "format": "date-time",
          "description": "When the email is deleted (14 days after it arrived)."
        }
      }
    }
  }
}