{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/makepartsnow-com/json-schema/makepartsnow-com-account-in-schema.json",
  "title": "AccountIn",
  "x-generated": "2026-11-18",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/makepartsnow-com-openapi.json#/components/schemas/AccountIn",
  "properties": {
    "name": {
      "type": "string",
      "maxLength": 255,
      "minLength": 1,
      "title": "Name",
      "description": "Agent or app name"
    },
    "organization": {
      "anyOf": [
        {
          "type": "string",
          "maxLength": 255
        },
        {
          "type": "null"
        }
      ],
      "title": "Organization"
    },
    "email": {
      "type": "string",
      "format": "email",
      "title": "Email",
      "description": "Receipts and order problems are sent here"
    },
    "ship_to": {
      "anyOf": [
        {
          "$ref": "#/$defs/Address"
        },
        {
          "type": "null"
        }
      ]
    },
    "callback_url": {
      "anyOf": [
        {
          "type": "string",
          "maxLength": 2083,
          "minLength": 1,
          "format": "uri"
        },
        {
          "type": "null"
        }
      ],
      "title": "Callback Url",
      "description": "Signed webhook events are POSTed here"
    },
    "accept_terms": {
      "type": "boolean",
      "title": "Accept Terms",
      "description": "Must be true: accepts the Terms of Sale and Agent Terms"
    }
  },
  "type": "object",
  "required": [
    "name",
    "email",
    "accept_terms"
  ],
  "$defs": {
    "Address": {
      "properties": {
        "name": {
          "type": "string",
          "maxLength": 255,
          "title": "Name"
        },
        "company": {
          "anyOf": [
            {
              "type": "string",
              "maxLength": 255
            },
            {
              "type": "null"
            }
          ],
          "title": "Company"
        },
        "line1": {
          "type": "string",
          "maxLength": 255,
          "title": "Line1"
        },
        "line2": {
          "anyOf": [
            {
              "type": "string",
              "maxLength": 255
            },
            {
              "type": "null"
            }
          ],
          "title": "Line2"
        },
        "city": {
          "type": "string",
          "maxLength": 128,
          "title": "City"
        },
        "state": {
          "type": "string",
          "maxLength": 64,
          "title": "State"
        },
        "postal_code": {
          "type": "string",
          "maxLength": 16,
          "title": "Postal Code"
        },
        "country": {
          "type": "string",
          "maxLength": 2,
          "title": "Country",
          "default": "US"
        },
        "phone": {
          "anyOf": [
            {
              "type": "string",
              "maxLength": 32
            },
            {
              "type": "null"
            }
          ],
          "title": "Phone"
        }
      },
      "type": "object",
      "required": [
        "name",
        "line1",
        "city",
        "state",
        "postal_code"
      ],
      "title": "Address"
    }
  }
}