> ## Documentation Index
> Fetch the complete documentation index at: https://docs.goshippo.com/llms.txt
> Use this file to discover all available pages before exploring further.

<AgentInstructions>

## Submitting Feedback

If you encounter incorrect, outdated, or confusing documentation on this page, submit feedback:

POST https://docs.goshippo.com/feedback

```json
{
  "path": "/api-reference/address-book/update-an-address",
  "feedback": "Description of the issue"
}
```

Only submit feedback when you have something specific and actionable to report.

</AgentInstructions>

# Update an address

> Updates values in an existing address



## OpenAPI

````yaml /api-reference/addressesapi/address_v2.yaml put /v2/addresses/{address_id}
openapi: 3.1.0
info:
  title: Shippo Address API
  summary: The Shippo Address API
  description: >-
    Address book, Address validation, and Address parsing <br>
    [https://goshippo.com](https://goshippo.com/)
  x-logo:
    url: https://docs.goshippo.com/images/shippo-logo.svg
  contact:
    name: Shippo Support
    url: https://support.goshippo.com/hc
    email: support@shippo.zendesk.com
  version: '0.1'
servers:
  - url: https://api.goshippo.com
security: []
tags:
  - name: Address Book
    description: Store, retrieve, modify, and delete your address book contacts
  - name: Validation
    description: Check your address is valid before creating shipping labels
  - name: Parser
    description: Convert address strings into a correctly formatted address object
paths:
  /v2/addresses/{address_id}:
    put:
      tags:
        - Address Book
      summary: Update an address
      description: Updates values in an existing address
      operationId: update_an_address_addresses__address_id__put
      parameters:
        - name: address_id
          in: path
          required: true
          schema:
            type: string
            title: Address Id
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/AddressRequest'
      responses:
        '204':
          description: Successful Response
        '404':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/NotFoundResponse'
          description: Not Found
        '409':
          content:
            application/json:
              schema:
                anyOf:
                  - properties:
                      detail:
                        default: Duplicate Address
                        examples:
                          - Duplicate Address
                        title: Detail
                        type: string
                    title: DuplicateAddressResponse
                    type: object
                  - properties:
                      detail:
                        type: string
                        title: Detail
                        default: Concurrent Write Conflict
                        examples:
                          - Concurrent Write Conflict
                    type: object
                    title: ConcurrentWriteConflictResponse
              examples:
                Duplicate address:
                  value:
                    detail: Duplicate Address
                Concurrent write conflict:
                  value:
                    detail: Concurrent Write Conflict
          description: Conflict
        '422':
          content:
            application/json:
              example:
                detail:
                  - type: enum
                    loc:
                      - body
                      - address_type
                    msg: Input should be 'unknown','residential' or 'commercial'
                    input: business
                    ctx:
                      expected: '''unknown'',''residential'' or ''commercial'''
              schema:
                $ref: '#/components/schemas/UnprocessableEntityResponse'
          description: Unprocessable Entity
        5XX:
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/InternalServerErrorResponse'
          description: Server Error
      security:
        - Shippo_Token: []
      x-codeSamples:
        - lang: cURL
          label: curl
          source: |-
            curl -i -X PUT \
            'https://api.goshippo.com/v2/addresses/{address_id}' \
            -H 'Authorization: ShippoToken <API_TOKEN>' \
            -H 'Content-Type: application/json' \
            -d '{
              "name": "Wilson",
              "organization": "Shippo",
              "email": "user@shippo.com",
              "phone": "+1-4155550132",
              "address_line_1": "731 Market Street",
              "address_line_2": "#200",
              "city_locality": "San Francisco",
              "state_province": "CA",
              "postal_code": "94103",
              "country_code": "US",
              "address_type": "residential"
            }'
components:
  schemas:
    AddressRequest:
      properties:
        name:
          type: string
          maxLength: 64
          title: Name
          description: The name of the addressee
          example: Wilson
        organization:
          anyOf:
            - type: string
              maxLength: 100
            - type: 'null'
          title: Organization
          description: The organization of the addressee
          example: Shippo
        email:
          anyOf:
            - type: string
              maxLength: 128
              minLength: 5
              format: email
            - type: 'null'
          title: Email
          description: The email of the addressee
          example: user@shippo.com
        phone:
          anyOf:
            - type: string
              maxLength: 32
              minLength: 3
            - type: 'null'
          title: Phone
          description: The phone number of the addressee
          example: +1-4155550132
        address_line_1:
          type: string
          maxLength: 100
          minLength: 1
          title: Address Line 1
          description: The first line of the address
          example: 731 Market Street
        address_line_2:
          anyOf:
            - type: string
              maxLength: 50
            - type: 'null'
          title: Address Line 2
          description: >-
            The second line of the address. Must be percent encoded when passed
            as a query parameter (e.g. `#200` → `%23200`).
          example: '#200'
        city_locality:
          anyOf:
            - type: string
              maxLength: 64
            - type: 'null'
          title: City Locality
          description: The city or locality of the address
          example: San Francisco
        state_province:
          anyOf:
            - type: string
              maxLength: 32
            - type: 'null'
          title: State Province
          description: The state, province, county, or municipal division
          example: CA
        postal_code:
          anyOf:
            - type: string
              maxLength: 16
            - type: 'null'
          type: string
          title: Postal Code
          description: The postal code or zip code
          example: '94103'
        country_code:
          type: string
          maxLength: 2
          minLength: 2
          title: Country Code
          description: The ISO 3166 country code
          example: US
        address_type:
          allOf:
            - $ref: '#/components/schemas/AddressType'
          description: >-
            The category of the address. It may affect how certain carriers
            charge for a delivery/pickup.It is recommended to specify it, if it
            is known.
          default: unknown
          example: residential
      type: object
      required:
        - name
        - address_line_1
        - country_code
      title: AddressRequest
    NotFoundResponse:
      properties:
        detail:
          type: string
          title: Detail
          default: Not Found
          examples:
            - Not Found
      type: object
      title: NotFoundResponse
    UnprocessableEntityResponse:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ErrorDetail'
          type: array
          title: Detail
          description: Details of the issue with the request.
      type: object
      required:
        - detail
      title: UnprocessableEntityResponse
      description: A response for invalid requests with details of the issue.
    InternalServerErrorResponse:
      properties:
        message:
          type: string
          title: Message
          description: The error message for an internal server error
          default: Internal Server Error
        trace_id:
          type: string
          title: Trace Id
          description: >-
            The OpenTelemetry trace identifier that is unique to the request. A
            valid trace identifier is a 16-byte array with at least one non-zero
            byte
          example: b562cab2e9200ac3e11474cc877580e1
      type: object
      required:
        - trace_id
      title: InternalServerErrorResponse
    AddressType:
      type: string
      enum:
        - unknown
        - residential
        - commercial
        - po_box
        - military
      title: AddressType
      description: >-
        The residential/commercial type of the address from the delivery/pickup
        standpoint


        `unknown` At the moment it is not possible to establish if the address
        is of any known type


        `residential` The address is a residence


        `commercial` The address is associated with a business


        `po_box` The address is a PO Box


        `military` The address is a military address
    ErrorDetail:
      properties:
        type:
          type: string
          title: Type
          description: The type of error
          examples:
            - missing
        loc:
          items:
            type: string
          type: array
          title: Loc
          description: The location of the error
          examples:
            - - query
              - country_code
        msg:
          type: string
          title: Msg
          description: The error message
          examples:
            - Field required
        input:
          anyOf:
            - {}
            - type: 'null'
          title: Input
          description: The input values for this field
          examples:
            - 'null'
      type: object
      required:
        - type
        - loc
        - msg
      title: ErrorDetail
  securitySchemes:
    Shippo_Token:
      type: apiKey
      description: |

        Enter your shippo token with the ShippoToken prefix.
        <br></br>
        Example: `ShippoToken shippo_live_xxxx`
      in: header
      name: Authorization
      x-default: 'ShippoToken '

````