Input & Output

Validate an existing address

The validateAddress endpoint is part of the Record Validation API, designed to validate and standardize address information. It checks the provided address against trusted external data sources and returns validation advice along with corrected or suggested addresses.

Authentication

The validateAddress endpoint requires authentication via Salesforce OAuth 2.0. Requests must include a valid OAuth access token in the Authorization header.

For detailed authentication steps, refer to: Salesforce Authentication Guide.

Method Signature

HTTP
POST /services/apexrest/recordval/v1/address/validate

Parameters

Type Variable Description
AddressValidationInput_v1 addressInput The structured input object containing address fields for validation.

Example Request

JSON
{
  "street": "Jansbuitensingel",
  "housenumber": "6",
  "state": "Gelderland",
  "city": "Arnhem",
  "postalcode": "6811AA",
  "country": "NL",
  "convertToSuggestionStatus": false,
  "note": "Testing the RV REST API",
  "addressOptions": {
    "housenumberAddition": false,
    "houseNumber": true,
    "geocode": true
  }
}

Output

Return Type: AddressValidationOutput_v1

Field Type Description
addresses List of Address_v1 A list of suggested validated addresses.
advice Advice_v1 Overall validation advice for the input (GREEN, AMBER, or RED). Use getAdvice() to retrieve as a string.
status Status_v1 Provides detailed information about the validation process.

Example Response

JSON
{
  "status": {
    "message": "Address validated successfully. Verified up to the Housenumber.",
    "credit": true,
    "code": "200"
  },
  "advice": "GREEN",
  "addresses": [
    {
      "street": "Jansbuitensingel 6",
      "stateCode": "GE",
      "state": "Gelderland",
      "postalCode": "6811 AA",
      "longitude": "5.898730",
      "latitude": "51.983500",
      "housenumberAddition": null,
      "housenumber": "6",
      "geoStatus": {
        "message": "High confidence geocode match.",
        "credit": true,
        "code": "700"
      },
      "fullAddress": "Jansbuitensingel 6, 6811 AA Arnhem",
      "countryCode": "NL",
      "country": "Netherlands",
      "city": "Arnhem",
      "advice": "GREEN"
    }
  ]
}