• Share
    • Twitter
    • LinkedIn
    • Facebook
    • Email
  • Feedback
  • Edit
Show / Hide Table of Contents

POST Agents/Contact/GetAddressByCountry

Some tooltip text!
• 4 minutes to read
 • 4 minutes to read
POST /api/v1/Agents/Contact/GetAddressByCountry

Gets the contact's localized address.

Query String Parameters

Parameter Name Type Description
$select string Optional comma separated list of properties to include in the result. Other fields are then nulled out to reduce payload size: "Name,department,category". Default = show all fields.
POST /api/v1/Agents/Contact/GetAddressByCountry?$select=name,department,category/id

Request Headers

Parameter Name Description
Authorization Supports 'Basic', 'SoTicket' and 'Bearer' schemes, depending on installation type.
X-XSRF-TOKEN If not using Authorization header, you must provide XSRF value from cookie or hidden input field
Content-Type Content-type of the request body: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded, application/json-patch+json, application/merge-patch+json
Accept Content-type(s) you would like the response in: application/json, text/json, application/xml, text/xml, application/json-patch+json, application/merge-patch+json
Accept-Language Convert string references and multi-language values into a specified language (iso2) code.
SO-Language Convert string references and multi-language values into a specified language (iso2) code. Overrides Accept-Language value.
SO-Culture Number, date formatting in a specified culture (iso2 language) code. Partially overrides SO-Language/Accept-Language value. Ignored if no Language set.
SO-TimeZone Specify the timezone code that you would like date/time responses converted to.
SO-AppToken The application token that identifies the partner app. Used when calling Online WebAPI from a server.

Request Body: request

ContactId, CountryId

Property Name Type Description
ContactId Integer
CountryId Integer

Response:

OK

Response Description
200 OK

Response body: Address

Property Name Type Description
Wgs84Latitude double Latitude (that's north/south), decimal degrees, relative to WGS 84 ellipsoid. SuperOffice ASA is at 59.91892. This value needs no further grid reference or other qualifying information.
Wgs84Longitude double Longitude (that's East/west), decimal degrees, relative to WGS 84 ellipsoid. SuperOffice ASA is at 10.73159. This value needs no further grid reference or other qualifying information.
LocalizedAddress array LocalizedFieldArray is a list of LocalizedFieldList objects. Used to store localized information such as formatted address data.
Street StructuredAddress Street address (company street, person address, delivery address). LocalizedAddress changes override this property, so you do not have to change both Localized and this.
Postal StructuredAddress Postal address (company postal, billing address). LocalizedAddress changes override this property, so you do not have to change both Localized and this.
Formatted string Read-only formatted address multi-line string. Combines street and postal into one string. e.g.: <c>"Postboks 123,\nBrugata 123,\n1234 OSLO\n"</c> or <c>"Postbox 123,\nBridgelane 123,\nWest Tooting,\nEast Shire ES2 W31\n"</c>.
TableRight TableRight The carrier's table right
FieldProperties object Field property dictionary mapping field names to field access rights.

Sample request

POST /api/v1/Agents/Contact/GetAddressByCountry
Authorization: Basic dGplMDpUamUw
Accept: application/json; charset=utf-8
Accept-Language: *
Content-Type: application/json; charset=utf-8

{
  "ContactId": 48,
  "CountryId": 531
}

Sample response

HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8

{
  "Wgs84Latitude": 8361.512,
  "Wgs84Longitude": 9050.992,
  "LocalizedAddress": [
    [
      {
        "Name": "Mohr Group",
        "Value": "vel",
        "Tooltip": "eligendi",
        "Label": "et",
        "ValueLength": 39,
        "AddressType": "quidem",
        "TableRight": null,
        "FieldProperties": {
          "fieldName": {
            "FieldRight": null,
            "FieldType": "System.Int32",
            "FieldLength": 917
          }
        }
      }
    ],
    [
      {
        "Name": "Pfannerstill Group",
        "Value": "tenetur",
        "Tooltip": "sit",
        "Label": "quia",
        "ValueLength": 177,
        "AddressType": "dolores",
        "TableRight": null,
        "FieldProperties": {
          "fieldName": {
            "FieldRight": null,
            "FieldType": "System.String",
            "FieldLength": 358
          }
        }
      }
    ]
  ],
  "Street": null,
  "Postal": null,
  "Formatted": "iste",
  "TableRight": null,
  "FieldProperties": {
    "fieldName": {
      "FieldRight": null,
      "FieldType": "System.String",
      "FieldLength": 288
    }
  }
}
© SuperOffice. All rights reserved.
SuperOffice |  Community |  Release Notes |  Privacy |  Site feedback |  Search Docs |  About Docs |  Contribute |  Back to top