Starfish API Documentation

updateAddress

Updates details of an address.

UpdateAddressMutationInput

Autogenerated input type of UpdateAddressMutation

UpdateAddressMutationPayload

Autogenerated return type of UpdateAddressMutation.

  • address: Address

  • clientMutationId: String

    A unique identifier for the client performing the mutation.

  • errors: [InputError!]!

    Validation errors

Query

mutation($input: UpdateAddressMutationInput!) {
  updateAddress(input: $input) {
    address {
      id
      firstName
      lastName
      addressLine1
      addressLine2
      addressLine3
      city
      region
      countryCode
      postalCode
      additionalInstructions
    }
    errors {
      message
      path
    }
  }
}

Variables

{
  "input": {
    "addressId": "Address-WXPFZMRQY4J",
    "firstName": "Britney",
    "lastName": "Johnson",
    "addressLine1": "44 Gateway Apartments",
    "addressLine2": "11 Station Approach",
    "addressLine3": "Hoe Street",
    "city": "London",
    "region": "London",
    "countryCode": "GB",
    "postalCode": "E17 9SL",
    "additionalInstructions": "Hand to reception"
  }
}

Response

{
  "data": {
    "updateAddress": {
      "address": {
        "id": "Address-WXPFZMRQY4J",
        "firstName": "Britney",
        "lastName": "Johnson",
        "addressLine1": "44 Gateway Apartments",
        "addressLine2": "11 Station Approach",
        "addressLine3": "Hoe Street",
        "city": "London",
        "region": "London",
        "countryCode": "GB",
        "postalCode": "E17 9SL",
        "additionalInstructions": "Hand to reception"
      },
      "errors": []
    }
  }
}