镜像站点 · 本页由第三方 GitHub 只读镜像提供,非 GitHub 官方站点,不接受任何登录或凭据输入。前往 github.com
Skip to content

Validate address endpoint violates the partial_address model validation #10

Open

Description

@nmusco

When calling the address validation endpoint it will sometimes respond with address_line2 of the matched address value set to an empty string instead of a null value. The partial_address model requires the address_line2 value be null or have a length > 0. This is causing issues with auto generated client libraries.

Rule:

        address_line2:
          type: string
          minLength: 1
          nullable: true
          example: Unit 408
          description: >
            The second line of the street address.  For some addresses, this
            line may not be needed.

Response:

[
  {
    "status": "verified",
    "original_address": {
      "name": "REDACTED",
      "phone": null,
      "company_name": null,
      "address_line1": "REDACTED",
      "address_line2": null,
      "address_line3": null,
      "city_locality": "REDACTED",
      "state_province": "REDACTED",
      "postal_code": "REDACTED",
      "country_code": "US",
      "address_residential_indicator": "unknown"
    },
    "matched_address": {
      "name": "REDACTED",
      "phone": null,
      "company_name": null,
      "address_line1": "REDACTED",
      "address_line2": "",
      "address_line3": null,
      "city_locality": "REDACTED",
      "state_province": "REDACTED",
      "postal_code": "REDACTED",
      "country_code": "US",
      "address_residential_indicator": "yes"
    },
    "messages": []
  }
]

Activity

  1. changed the title [-]validate address endpoint violates the partial_address model validation[/-] [+]Validate address endpoint violates the partial_address model validation[/+] on Dec 18, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions