Mailchimp Orders API

The Orders API from Mailchimp — 5 operation(s) for orders.

Documentation

Specifications

Schemas & Data

Other Resources

OpenAPI Specification

mailchimp-orders-api-openapi.yml Raw ↑
swagger: '2.0'
info:
  version: 3.0.55
  title: Mailchimp Marketing Abuse Orders API
  contact:
    name: Mailchimp API Support
    email: apihelp@mailchimp.com
  x-permalink: https://github.com/mailchimp/mailchimp-client-lib-codegen/blob/main/spec/marketing.json
  description: '

    The Mailchimp Marketing API provides programmatic access to Mailchimp data

    and functionality, allowing developers to build custom features to do

    things like sync email activity and campaign analytics with their

    database, manage audiences and campaigns, and more.'
host: server.api.mailchimp.com
basePath: /3.0
schemes:
- https
consumes:
- application/json
produces:
- application/json
- application/problem+json
security:
- basicAuth: []
tags:
- name: Orders
paths:
  /ecommerce/orders:
    get:
      summary: Mailchimp List Account Orders
      description: Get information about an account's orders.
      operationId: getEcommerceOrders
      parameters:
      - name: fields
        x-title: Fields
        in: query
        description: A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
        required: false
        type: array
        collectionFormat: csv
        items:
          type: string
        example: example_value
      - name: exclude_fields
        x-title: Exclude Fields
        in: query
        description: A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
        required: false
        type: array
        collectionFormat: csv
        items:
          type: string
        example: example_value
      - name: count
        x-title: Count
        in: query
        description: The number of records to return. Default value is 10. Maximum value is 1000
        required: false
        default: 10
        maximum: 1000
        type: integer
        example: example_value
      - name: offset
        x-title: Offset
        in: query
        description: Used for [pagination](https://mailchimp.com/developer/marketing/docs/methods-parameters/#pagination), this it the number of records from a collection to skip. Default value is 0.
        required: false
        default: 0
        type: integer
        example: example_value
      - name: campaign_id
        x-title: Campaign ID
        in: query
        description: Restrict results to orders with a specific `campaign_id` value.
        required: false
        type: string
        example: '500123'
      - name: outreach_id
        x-title: Outreach ID
        in: query
        description: Restrict results to orders with a specific `outreach_id` value.
        required: false
        type: string
        example: '500123'
      - name: customer_id
        x-title: Customer ID
        in: query
        required: false
        description: Restrict results to orders made by a specific customer.
        type: string
        example: '500123'
      - name: has_outreach
        x-title: Has Outreach
        in: query
        required: false
        description: Restrict results to orders that have an outreach attached. For example, an email campaign or Facebook ad.
        type: boolean
        example: example_value
      responses:
        '200':
          description: ''
          schema:
            type: object
            title: Orders
            description: A collection of orders in an account.
            properties:
              orders:
                type: array
                title: Orders
                description: An array of objects, each representing an order resource.
                items:
                  type: object
                  title: E-commerce Order
                  description: Information about a specific order.
                  properties:
                    id:
                      type: string
                      title: Order Foreign ID
                      description: A unique identifier for the order.
                      readOnly: true
                    customer:
                      type: object
                      title: E-commerce Customer
                      description: Information about a specific customer.
                      properties:
                        id:
                          type: string
                          title: Customer Foreign ID
                          description: A unique identifier for the customer.
                          readOnly: true
                        email_address:
                          type: string
                          title: Email Address
                          description: The customer's email address.
                          readOnly: true
                        opt_in_status:
                          type: boolean
                          title: Opt-in Status
                          description: The customer's opt-in status. This value will never overwrite the opt-in status of a pre-existing Mailchimp list member, but will apply to list members that are added through the e-commerce API endpoints. Customers who don't opt in to your Mailchimp list [will be added as `Transactional` members](https://mailchimp.com/developer/marketing/docs/e-commerce/#customers).
                        company:
                          type: string
                          title: Company
                          description: The customer's company.
                        first_name:
                          type: string
                          title: First Name
                          description: The customer's first name.
                        last_name:
                          type: string
                          title: Last Name
                          description: The customer's last name.
                        orders_count:
                          type: integer
                          title: Orders Count
                          description: The customer's total order count.
                          readOnly: true
                          example: 4
                        total_spent:
                          type: number
                          title: Total Spent
                          description: The total amount the customer has spent.
                          readOnly: true
                          example: 100
                        address:
                          type: object
                          title: Address
                          description: The customer's address.
                          properties:
                            address1:
                              type: string
                              title: Address Field 1
                              description: The mailing address of the customer.
                              example: 675 Ponce de Leon Ave NE
                            address2:
                              type: string
                              title: Address Field 2
                              description: An additional field for the customer's mailing address.
                              example: Suite 5000
                            city:
                              type: string
                              title: 'City '
                              description: The city the customer is located in.
                              example: Atlanta
                            province:
                              type: string
                              title: Province
                              description: The customer's state name or normalized province.
                              example: Georgia
                            province_code:
                              type: string
                              title: Province Code
                              description: The two-letter code for the customer's province or state.
                              example: GA
                            postal_code:
                              type: string
                              title: Postal Code
                              description: The customer's postal or zip code.
                              example: '30308'
                            country:
                              type: string
                              title: Country Code
                              description: The customer's country.
                              example: United States
                            country_code:
                              type: string
                              title: Country Code
                              description: The two-letter code for the customer's country.
                              example: US
                        created_at:
                          type: string
                          title: Creation Time
                          format: date-time
                          description: The date and time the customer was created in ISO 8601 format.
                          readOnly: true
                          example: '2015-07-15T19:28:00+00:00'
                        updated_at:
                          type: string
                          title: Update Time
                          format: date-time
                          description: The date and time the customer was last updated in ISO 8601 format.
                          readOnly: true
                          example: '2015-07-15T19:28:00+00:00'
                        _links:
                          title: Links
                          description: A list of link types and descriptions for the API schema documents.
                          type: array
                          items:
                            type: object
                            title: Resource Link
                            description: This object represents a link from the resource where it is found to another resource or action that may be performed.
                            properties:
                              rel:
                                type: string
                                title: Rel
                                description: As with an HTML 'rel' attribute, this describes the type of link.
                                readOnly: true
                              href:
                                type: string
                                title: Href
                                description: This property contains a fully-qualified URL that can be called to retrieve the linked resource or perform the linked action.
                                readOnly: true
                              method:
                                type: string
                                title: Method
                                description: The HTTP method that should be used when accessing the URL defined in 'href'.
                                enum:
                                - GET
                                - POST
                                - PUT
                                - PATCH
                                - DELETE
                                - OPTIONS
                                - HEAD
                                readOnly: true
                              targetSchema:
                                type: string
                                title: Target Schema
                                description: For GETs, this is a URL representing the schema that the response should conform to.
                                readOnly: true
                              schema:
                                type: string
                                title: Schema
                                description: For HTTP methods that can receive bodies (POST and PUT), this is a URL representing the schema that the body should conform to.
                                readOnly: true
                          readOnly: true
                    store_id:
                      type: string
                      title: Store Foreign ID
                      description: The unique identifier for the store.
                      readOnly: true
                    campaign_id:
                      type: string
                      title: Campaign ID
                      description: A string that uniquely identifies the campaign associated with an order.
                      example: 839488a60b
                    landing_site:
                      type: string
                      title: Landing Site
                      description: The URL for the page where the buyer landed when entering the shop.
                      example: http://www.example.com?source=abc
                    financial_status:
                      type: string
                      title: Financial Status
                      description: The order status. Use this parameter to trigger [Order Notifications](https://mailchimp.com/developer/marketing/docs/e-commerce/#order-notifications).
                    fulfillment_status:
                      type: string
                      title: Fulfillment Status
                      description: The fulfillment status for the order. Use this parameter to trigger [Order Notifications](https://mailchimp.com/developer/marketing/docs/e-commerce/#order-notifications).
                    currency_code:
                      type: string
                      title: Currency Code
                      description: The three-letter ISO 4217 code for the currency that the store accepts.
                    order_total:
                      type: number
                      title: Order Total
                      description: The order total associated with an order.
                    order_url:
                      type: string
                      title: Order URL
                      description: The URL for the order.
                    discount_total:
                      type: number
                      title: Discount Total
                      description: The total amount of the discounts to be applied to the price of the order.
                    tax_total:
                      type: number
                      title: Tax Total
                      description: The tax total associated with an order.
                    shipping_total:
                      type: number
                      title: Shipping Total
                      description: The shipping total for the order.
                    tracking_code:
                      type: string
                      enum:
                      - prec
                      title: Tracking Code
                      description: The Mailchimp tracking code for the order. Uses the 'mc_tc' parameter in E-Commerce tracking URLs.
                    processed_at_foreign:
                      type: string
                      title: Foreign Processed Time
                      format: date-time
                      description: The date and time the order was processed in ISO 8601 format.
                      example: '2015-07-15T19:28:00+00:00'
                    cancelled_at_foreign:
                      type: string
                      title: Foreign Cancel Time
                      format: date-time
                      description: The date and time the order was cancelled in ISO 8601 format.
                      example: '2015-07-15T19:28:00+00:00'
                    updated_at_foreign:
                      type: string
                      title: Foreign Update Time
                      format: date-time
                      description: The date and time the order was updated in ISO 8601 format.
                      example: '2015-07-15T19:28:00+00:00'
                    shipping_address:
                      type: object
                      title: Shipping Address
                      description: The shipping address for the order.
                      properties:
                        name:
                          type: string
                          title: Name
                          description: The name associated with an order's shipping address.
                          example: Freddie Chimpenheimer
                        address1:
                          type: string
                          title: Address Field 1
                          description: The shipping address for the order.
                          example: 675 Ponce de Leon Ave NE
                        address2:
                          type: string
                          title: Address Field 2
                          description: An additional field for the shipping address.
                          example: Suite 5000
                        city:
                          type: string
                          title: 'City '
                          description: The city in the order's shipping address.
                          example: Atlanta
                        province:
                          type: string
                          title: Province
                          description: The state or normalized province in the order's shipping address.
                          example: Georgia
                        province_code:
                          type: string
                          title: Province Code
                          description: The two-letter code for the province or state the order's shipping address is located in.
                          example: GA
                        postal_code:
                          type: string
                          title: Postal Code
                          description: The postal or zip code in the order's shipping address.
                          example: '30308'
                        country:
                          type: string
                          title: Country Code
                          description: The country in the order's shipping address.
                          example: United States
                        country_code:
                          type: string
                          title: Country Code
                          description: The two-letter code for the country in the shipping address.
                          example: US
                        longitude:
                          type: number
                          title: Longitude
                          description: The longitude for the shipping address location.
                          example: -75.68903
                        latitude:
                          type: number
                          title: Latitude
                          description: The latitude for the shipping address location.
                          example: 45.427408
                        phone:
                          type: string
                          title: Phone Number
                          description: The phone number for the order's shipping address
                          example: '8675309'
                        company:
                          type: string
                          title: Company
                          description: The company associated with an order's shipping address.
                    billing_address:
                      type: object
                      title: Billing Address
                      description: The billing address for the order.
                      properties:
                        name:
                          type: string
                          title: Name
                          description: The name associated with an order's billing address.
                          example: Freddie Chimpenheimer
                        address1:
                          type: string
                          title: Address Field 1
                          description: The billing address for the order.
                          example: 675 Ponce de Leon Ave NE
                        address2:
                          type: string
                          title: Address Field 2
                          description: An additional field for the billing address.
                          example: Suite 5000
                        city:
                          type: string
                          title: 'City '
                          description: The city in the billing address.
                          example: Atlanta
                        province:
                          type: string
                          title: Province
                          description: The state or normalized province in the billing address.
                          example: Georgia
                        province_code:
                          type: string
                          title: Province Code
                          description: The two-letter code for the province or state in the billing address.
                          example: GA
                        postal_code:
                          type: string
                          title: Postal Code
                          description: The postal or zip code in the billing address.
                          example: '30308'
                        country:
                          type: string
                          title: Country Code
                          description: The country in the billing address.
                          example: United States
                        country_code:
                          type: string
                          title: Country Code
                          description: The two-letter code for the country in the billing address.
                          example: US
                        longitude:
                          type: number
                          title: Longitude
                          description: The longitude for the billing address location.
                          example: -75.68903
                        latitude:
                          type: number
                          title: Latitude
                          description: The latitude for the billing address location.
                          example: 45.427408
                        phone:
                          type: string
                          title: Phone Number
                          description: The phone number for the billing address.
                          example: '8675309'
                        company:
                          type: string
                          title: Company
                          description: The company associated with the billing address.
                    promos:
                      type: array
                      title: Promos
                      description: The promo codes applied on the order
                      items:
                        type: object
                        properties:
                          code:
                            type: string
                            title: Code
                            description: The Promo Code
                          amount_discounted:
                            type: number
                            title: Amount Discounted
                            description: The amount of discount applied on the total price. For example if the total cost was $100 and the customer paid $95.5, amount_discounted will be 4.5 For free shipping set amount_discounted to 0
                          type:
                            type: string
                            title: Type
                            description: Type of discount. For free shipping set type to fixed
                            enum:
                            - fixed
                            - percentage
                    lines:
                      type: array
                      title: Order Line Items
                      description: An array of the order's line items.
                      items:
                        type: object
                        title: E-commerce Order Line Item
                        description: Information about a specific order line.
                        properties:
                          id:
                            type: string
                            title: Order Line Item Foreign ID
                            description: A unique identifier for an order line item.
                            readOnly: true
                          product_id:
                            type: string
                            title: Order Line Item Product Foreign ID
                            description: A unique identifier for the product associated with an order line item.
                          product_title:
                            type: string
                            title: Order Line Item Product Title
                            description: The name of the product for an order line item.
                            readOnly: true
                          product_variant_id:
                            type: string
                            title: Order Line Item Product Variant Foreign ID
                            description: A unique identifier for the product variant associated with an order line item.
                          product_variant_title:
                            type: string
                            title: Order Line Item Product Variant Title
                            description: The name of the product variant for an order line item.
                            readOnly: true
                          image_url:
                            type: string
                            title: Product Image URL
                            description: The image URL for a product.
                            readOnly: true
                          quantity:
                            type: integer
                            title: Quantity
                            description: The order line item quantity.
                          price:
                            type: number
                            title: Price
                            description: The order line item price.
                          discount:
                            type: number
                            title: Discount
                            description: The total discount amount applied to a line item.
                          _links:
                            title: Links
                            description: A list of link types and descriptions for the API schema documents.
                            type: array
                            items:
                              type: object
                              title: Resource Link
                              description: This object represents a link from the resource where it is found to another resource or action that may be performed.
                              properties:
                                rel:
                                  type: string
                                  title: Rel
                                  description: As with an HTML 'rel' attribute, this describes the type of link.
                                  readOnly: true
                                href:
                                  type: string
                                  title: Href
                                  description: This property contains a fully-qualified URL that can be called to retrieve the linked resource or perform the linked action.
                                  readOnly: true
                                method:
                                  type: string
                                  title: Method
                                  description: The HTTP method that should be used when accessing the URL defined in 'href'.
                                  enum:
                                  - GET
                                  - POST
                                  - PUT
                                  - PATCH
                                  - DELETE
                                  - OPTIONS
                                  - HEAD
                                  readOnly: true
                                targetSchema:
                                  type: string
                                  title: Target Schema
                                  description: For GETs, this is a URL representing the schema that the response should conform to.
                                  readOnly: true
                                schema:
                                  type: string
                                  title: Schema
                                  description: For HTTP methods that can receive bodies (POST and PUT), this is a URL representing the schema that the body should conform to.
                                  readOnly: true
                            readOnly: true
                    outreach:
                      type: object
                      title: Outreach
                      description: The outreach associated with this order. For example, an email campaign or Facebook ad.
                      properties:
                        id:
                          type: string
                          title: Outreach ID
                          description: A unique identifier for the outreach. Can be an email campaign ID.
                          example: 839488a60b
                        name:
                          type: string
                          title: Outreach name
                          description: The name for the outreach.
                          example: Freddie's Jokes
                          readOnly: true
                        type:
                          type: string
                          title: Outreach type
                          description: The type of the outreach.
                          example: regular
                          readOnly: true
                        published_time:
                          type: string
                          format: date-time
                          title: Outreach published time
                          description: The date and time the Outreach was published in ISO 8601 format.
                          example: '2017-06-06T13:56:12+00:00'
                          readOnly: true
                    tracking_number:
                      type: string
                      title: Tracking number
                      description: The tracking number associated with the order.
                    tracking_carrier:
                      type: string
                      title: Tracking carrier
                      description: The tracking carrier associated with the order.
                    tracking_url:
                      type: string
                      title: Tracking URL
                      description: The tracking URL associated with the order.
                    _links:
                      title: Links
                      description: A list of link types and descriptions for the API schema documents.
                      type: array
                      items:
                        type: object
                        title: Resource Link
                        description: This object represents a link from the resource where it is found to another resource or action that may be performed.
                        properties:
                          rel:
                            type: string
                            title: Rel
                            description: As with an HTML 'rel' attribute, this describes the type of link.
                            readOnly: true
                          href:
                            type: string
                            title: Href
                            description: This property contains a fully-qualified URL that can be called to retrieve the linked resource or perform the linked action.
                            readOnly: true
                          method:
                            type: string
                            title: Method
                            description: The HTTP method that should be used when accessing the URL defined in 'href'.
                            enum:
                            - GET
                            - POST
                            - PUT
                            - PATCH
                            - DELETE
                            - OPTIONS
                            - HEAD
                            readOnly: true
                          targetSchema:
                       

# --- truncated at 32 KB (258 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/mailchimp/refs/heads/main/openapi/mailchimp-orders-api-openapi.yml