Optimizely Order Histories API

The Order Histories API from Optimizely — 8 operation(s) for order histories.

Operations 12

Each operation below carries the questions people ask an LLM about it and the instructions they give an agent to run it. Generated by API Evangelist overlay

GET /api/v1/admin/OrderHistories List historical orders · Returns the EntitySet OrderHistories #
Ask an LLM
“How do I pull the order history synced from our ERP into the commerce admin?”
“Can I filter past orders by customer number or status?”
Tell an agent
List all order history records.
List order histories matching {filter}, newest first by {orderby}.
POST /api/v1/admin/OrderHistories Add a historical order record · Post a new entity to EntitySet OrderHistories #
Ask an LLM
“How do I load an order from our ERP into the order history?”
“What bill-to and ship-to fields does a new order history record need?”
Tell an agent
Create an order history for ERP order {erpOrderNumber} for customer {customerNumber} with status {status}.
Add web order {webOrderNumber} with PO {customerPO} to order history.
GET /api/v1/admin/OrderHistories({id}) Get one historical order · Returns the entity with the key from OrderHistories #
Ask an LLM
“How do I see the totals and addresses on one past order?”
“Can I expand the lines of a single order history record?”
Tell an agent
Get order history {id}.
Show order history {id} with {expand} expanded.
PUT /api/v1/admin/OrderHistories({id}) Replace a historical order record · Replace entity in EntitySet OrderHistories #
Ask an LLM
“How do I overwrite a whole order history record with fresh ERP data?”
“Is there a way to fully replace a past order rather than patch it?”
Tell an agent
Replace order history {id} with the full record for ERP order {erpOrderNumber}.
Overwrite past order {id} entirely, with order total {orderTotal}.
DELETE /api/v1/admin/OrderHistories({id}) Delete a historical order · Delete entity in EntitySet OrderHistories #
Ask an LLM
“How do I remove one order from the order history?”
“Can I delete a past order only if nobody changed it since I read it?”
Tell an agent destructive · confirm first
Delete order history {id}.
Remove past order {id} if its ETag is still {etag}.
PATCH /api/v1/admin/OrderHistories({id}) Update fields on a historical order · Update entity in EntitySet OrderHistories #
Ask an LLM
“How do I change the status of a past order in order history?”
“Can I update just the notes on an order history record?”
Tell an agent
Set the status of order history {id} to {status}.
Update the notes on past order {id} to {notes}.
GET /api/v1/admin/OrderHistories/Default.Default() Get a blank order history template · Call operation Default #
Ask an LLM
“What default values does a new order history record start with?”
“Can I fetch an empty order history template before loading orders?”
Tell an agent
Fetch the default order history template.
Show me the starting values for a new order history record.
DELETE /api/v1/admin/orderhistories/delete Bulk delete historical orders · Order histories delete route #
Ask an LLM
“How do I delete several past orders at once?”
“Can I purge a batch of order history records by ID?”
Tell an agent destructive · confirm first
Bulk delete the order histories with IDs {ids}.
Remove these past orders in one call: {ids}.
GET /api/v1/admin/orderhistories({key})/customproperties({custompropertyKey}) Get a custom property on a historical order · Order histories get custom property by key and custompropertykey #
Ask an LLM
“How do I read a custom property stored on a past order?”
“Can I fetch one extra field value from an order history record?”
Tell an agent
Get custom property {custompropertyKey} on order history {key}.
Show the custom property {custompropertyKey} of past order {key}.
GET /api/v1/admin/orderhistories({key})/orderhistorylines({orderhistorylineKey}) Get a line item on a historical order · Order histories get order history line by key and orderhistorylinekey #
Ask an LLM
“How do I see a single product line from a past order?”
“Can I read one order history line by its key?”
Tell an agent
Get line {orderhistorylineKey} of order history {key}.
Show product line {orderhistorylineKey} on past order {key}.
GET /api/v1/admin/orderhistories({key})/orderhistorypromotions({orderhistorypromotionKey}) Get a promotion applied to a historical order · Order histories get order history promotion by key and orderhistorypromotionkey #
Ask an LLM
“Which promotion was applied to a past order?”
“Can I read one order history promotion record by its key?”
Tell an agent
Get promotion {orderhistorypromotionKey} on order history {key}.
Show the promotion {orderhistorypromotionKey} applied to past order {key}.
GET /api/v1/admin/orderhistories({key})/orderhistorytaxes({orderhistorytaxKey}) Get a tax entry on a historical order · Order histories get order history tax by key and orderhistorytaxkey #
Ask an LLM
“How do I see the tax breakdown entry for a past order?”
“Can I read one order history tax record by its key?”
Tell an agent
Get tax entry {orderhistorytaxKey} on order history {key}.
Show tax line {orderhistorytaxKey} for past order {key}.

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/optimizely:optimizely-order-histories-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

optimizely-order-histories-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  version: admin-v1
  title: Admin API V1 Order Histories API
servers:
- url: https://dogfood.commerce.insitesandbox.com
security: []
tags:
- name: Order Histories
paths:
  /api/v1/admin/OrderHistories:
    get:
      tags:
      - Order Histories
      summary: Returns the EntitySet OrderHistories
      operationId: OrderHistories_Get
      parameters:
      - name: $expand
        in: query
        description: Expands related entities inline.
        required: false
        schema:
          type: string
      - name: $filter
        in: query
        description: Filters the results, based on a Boolean condition.
        required: false
        schema:
          type: string
      - name: $select
        in: query
        description: Selects which properties to include in the response.
        required: false
        schema:
          type: string
      - name: $apply
        in: query
        description: Aggregates the results according to one or more transformations.
        required: false
        schema:
          type: string
      - name: $orderby
        in: query
        description: Sorts the results.
        required: false
        schema:
          type: string
      - name: $top
        in: query
        description: Returns only the first n results.
        required: false
        schema:
          type: integer
          format: int32
      - name: $skip
        in: query
        description: Skips the first n results.
        required: false
        schema:
          type: integer
          format: int32
      - name: $count
        in: query
        description: Includes a count of the matching results in the response.
        required: false
        schema:
          type: boolean
      responses:
        '200':
          description: OK
          content:
            '*/*':
              schema:
                type: object
      deprecated: false
      security:
      - access_token: []
    post:
      tags:
      - Order Histories
      summary: Post a new entity to EntitySet OrderHistories
      operationId: OrderHistories_Post
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Insite.Data.Entities.OrderHistory'
        description: The entity to post
        required: true
      responses:
        '200':
          description: OK
          content:
            '*/*':
              schema:
                type: object
      deprecated: false
      security:
      - access_token: []
  /api/v1/admin/OrderHistories({id}):
    get:
      tags:
      - Order Histories
      summary: Returns the entity with the key from OrderHistories
      operationId: OrderHistories_GetById
      parameters:
      - name: id
        in: path
        description: 'key: id'
        required: true
        schema:
          type: string
          format: uuid
      - name: $expand
        in: query
        description: Expands related entities inline.
        required: false
        schema:
          type: string
      - name: $select
        in: query
        description: Selects which properties to include in the response.
        required: false
        schema:
          type: string
      responses:
        '200':
          description: OK
          content:
            '*/*':
              schema:
                type: object
      deprecated: false
      security:
      - access_token: []
    put:
      tags:
      - Order Histories
      summary: Replace entity in EntitySet OrderHistories
      operationId: OrderHistories_PutById
      parameters:
      - name: id
        in: path
        description: 'key: id'
        required: true
        schema:
          type: string
          format: uuid
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Insite.Data.Entities.OrderHistory'
        description: The entity to put
        required: true
      responses:
        '200':
          description: OK
          content:
            '*/*':
              schema:
                type: object
      deprecated: false
      security:
      - access_token: []
    delete:
      tags:
      - Order Histories
      summary: Delete entity in EntitySet OrderHistories
      operationId: OrderHistories_DeleteById
      parameters:
      - name: id
        in: path
        description: 'key: id'
        required: true
        schema:
          type: string
          format: uuid
      - name: If-Match
        in: header
        description: If-Match header
        required: false
        schema:
          type: string
      responses:
        '200':
          description: OK
          content:
            '*/*':
              schema:
                type: object
      deprecated: false
      security:
      - access_token: []
    patch:
      tags:
      - Order Histories
      summary: Update entity in EntitySet OrderHistories
      operationId: OrderHistories_PatchById
      parameters:
      - name: id
        in: path
        description: 'key: id'
        required: true
        schema:
          type: string
          format: uuid
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/Insite.Data.Entities.OrderHistory'
        description: The entity to patch
        required: true
      responses:
        '200':
          description: OK
          content:
            '*/*':
              schema:
                type: object
      deprecated: false
      security:
      - access_token: []
  /api/v1/admin/OrderHistories/Default.Default():
    get:
      tags:
      - Order Histories
      summary: Call operation Default
      operationId: OrderHistories_Default
      responses:
        '200':
          description: OK
          content:
            '*/*':
              schema:
                type: object
      deprecated: false
      security:
      - access_token: []
  /api/v1/admin/orderhistories/delete:
    delete:
      tags:
      - Order Histories
      operationId: OrderHistories_DeleteRoute
      parameters:
      - name: ids
        in: query
        required: true
        explode: true
        schema:
          type: array
          items:
            type: string
            format: uuid
      responses:
        '200':
          description: OK
          content:
            '*/*':
              schema:
                type: object
      deprecated: false
      security:
      - access_token: []
      summary: Order histories delete route
      x-summary-source: derived
  /api/v1/admin/orderhistories({key})/customproperties({custompropertyKey}):
    get:
      tags:
      - Order Histories
      operationId: OrderHistories_GetCustomPropertyByKeyAndCustompropertykey
      parameters:
      - name: key
        in: path
        required: true
        schema:
          type: string
          format: uuid
      - name: custompropertyKey
        in: path
        required: true
        schema:
          type: string
          format: uuid
      - name: $expand
        in: query
        description: Expands related entities inline.
        required: false
        schema:
          type: string
      - name: $select
        in: query
        description: Selects which properties to include in the response.
        required: false
        schema:
          type: string
      responses:
        '200':
          description: OK
          content:
            '*/*':
              schema:
                type: object
      deprecated: false
      security:
      - access_token: []
      summary: Order histories get custom property by key and custompropertykey
      x-summary-source: derived
  /api/v1/admin/orderhistories({key})/orderhistorylines({orderhistorylineKey}):
    get:
      tags:
      - Order Histories
      operationId: OrderHistories_GetOrderHistoryLineByKeyAndOrderhistorylinekey
      parameters:
      - name: key
        in: path
        required: true
        schema:
          type: string
          format: uuid
      - name: orderhistorylineKey
        in: path
        required: true
        schema:
          type: string
          format: uuid
      - name: $expand
        in: query
        description: Expands related entities inline.
        required: false
        schema:
          type: string
      - name: $select
        in: query
        description: Selects which properties to include in the response.
        required: false
        schema:
          type: string
      responses:
        '200':
          description: OK
          content:
            '*/*':
              schema:
                type: object
      deprecated: false
      security:
      - access_token: []
      summary: Order histories get order history line by key and orderhistorylinekey
      x-summary-source: derived
  /api/v1/admin/orderhistories({key})/orderhistorypromotions({orderhistorypromotionKey}):
    get:
      tags:
      - Order Histories
      operationId: OrderHistories_GetOrderHistoryPromotionByKeyAndOrderhistorypromotionkey
      parameters:
      - name: key
        in: path
        required: true
        schema:
          type: string
          format: uuid
      - name: orderhistorypromotionKey
        in: path
        required: true
        schema:
          type: string
          format: uuid
      - name: $expand
        in: query
        description: Expands related entities inline.
        required: false
        schema:
          type: string
      - name: $select
        in: query
        description: Selects which properties to include in the response.
        required: false
        schema:
          type: string
      responses:
        '200':
          description: OK
          content:
            '*/*':
              schema:
                type: object
      deprecated: false
      security:
      - access_token: []
      summary: Order histories get order history promotion by key and orderhistorypromotionkey
      x-summary-source: derived
  /api/v1/admin/orderhistories({key})/orderhistorytaxes({orderhistorytaxKey}):
    get:
      tags:
      - Order Histories
      operationId: OrderHistories_GetOrderHistoryTaxByKeyAndOrderhistorytaxkey
      parameters:
      - name: key
        in: path
        required: true
        schema:
          type: string
          format: uuid
      - name: orderhistorytaxKey
        in: path
        required: true
        schema:
          type: string
          format: uuid
      - name: $expand
        in: query
        description: Expands related entities inline.
        required: false
        schema:
          type: string
      - name: $select
        in: query
        description: Selects which properties to include in the response.
        required: false
        schema:
          type: string
      responses:
        '200':
          description: OK
          content:
            '*/*':
              schema:
                type: object
      deprecated: false
      security:
      - access_token: []
      summary: Order histories get order history tax by key and orderhistorytaxkey
      x-summary-source: derived
components:
  schemas:
    Insite.Data.Entities.OrderHistory:
      required:
      - erpOrderNumber
      - webOrderNumber
      - status
      - customerNumber
      - customerSequence
      - customerPO
      - currencyCode
      - terms
      - shipCode
      - salesperson
      - btCompanyName
      - btAddress1
      - btAddress2
      - btAddress3
      - btAddress4
      - btCity
      - btState
      - btPostalCode
      - btCountry
      - stCompanyName
      - stAddress1
      - stAddress2
      - stAddress3
      - stAddress4
      - stCity
      - stState
      - stPostalCode
      - stCountry
      - notes
      - fulfillmentMethod
      - customerVatNumber
      - vmiLocationName
      - orderSource
      - orderDeviceType
      type: object
      properties:
        id:
          format: uuid
          type: string
          example: 00000000-0000-0000-0000-000000000000
        erpOrderNumber:
          maxLength: 50
          minLength: 0
          type: string
        webOrderNumber:
          maxLength: 50
          minLength: 0
          type: string
        orderDate:
          format: date-time
          type: string
        status:
          maxLength: 50
          minLength: 0
          type: string
        customerNumber:
          maxLength: 50
          minLength: 0
          type: string
        customerSequence:
          maxLength: 50
          minLength: 0
          type: string
        customerPO:
          maxLength: 50
          minLength: 0
          type: string
        currencyCode:
          maxLength: 50
          minLength: 0
          type: string
        terms:
          maxLength: 50
          minLength: 0
          type: string
        shipCode:
          maxLength: 50
          minLength: 0
          type: string
        salesperson:
          maxLength: 50
          minLength: 0
          type: string
        btCompanyName:
          maxLength: 100
          minLength: 0
          type: string
        btAddress1:
          maxLength: 100
          minLength: 0
          type: string
        btAddress2:
          maxLength: 100
          minLength: 0
          type: string
        btAddress3:
          maxLength: 100
          minLength: 0
          type: string
        btAddress4:
          maxLength: 100
          minLength: 0
          type: string
        btCity:
          maxLength: 100
          minLength: 0
          type: string
        btState:
          maxLength: 50
          minLength: 0
          type: string
        btPostalCode:
          maxLength: 50
          minLength: 0
          type: string
        btCountry:
          maxLength: 100
          minLength: 0
          type: string
        stCompanyName:
          maxLength: 100
          minLength: 0
          type: string
        stAddress1:
          maxLength: 100
          minLength: 0
          type: string
        stAddress2:
          maxLength: 100
          minLength: 0
          type: string
        stAddress3:
          maxLength: 100
          minLength: 0
          type: string
        stAddress4:
          maxLength: 100
          minLength: 0
          type: string
        stCity:
          maxLength: 100
          minLength: 0
          type: string
        stState:
          maxLength: 50
          minLength: 0
          type: string
        stPostalCode:
          maxLength: 50
          minLength: 0
          type: string
        stCountry:
          maxLength: 100
          minLength: 0
          type: string
        notes:
          type: string
        productTotal:
          format: decimal
          type: number
        orderDiscountAmount:
          format: decimal
          type: number
        productDiscountAmount:
          format: decimal
          type: number
        shippingCharges:
          format: decimal
          type: number
        handlingCharges:
          format: decimal
          type: number
        otherCharges:
          format: decimal
          type: number
        taxAmount:
          format: decimal
          type: number
        orderTotal:
          format: decimal
          type: number
        conversionRate:
          format: double
          type: number
        requestedDeliveryDate:
          format: date-time
          type: string
        impersonatedByAdminUserProfileId:
          format: uuid
          type: string
          example: 00000000-0000-0000-0000-000000000000
        isGuestOrder:
          type: boolean
        fulfillmentMethod:
          maxLength: 50
          minLength: 0
          type: string
        customerVatNumber:
          maxLength: 50
          minLength: 0
          type: string
        shippingVatAmount:
          format: decimal
          type: number
        vmiLocationId:
          format: uuid
          type: string
          example: 00000000-0000-0000-0000-000000000000
        vmiLocationName:
          maxLength: 255
          minLength: 0
          type: string
        orderSource:
          maxLength: 50
          minLength: 0
          type: string
        orderDeviceType:
          maxLength: 50
          minLength: 0
          type: string
        createdOn:
          format: date-time
          type: string
        createdBy:
          type: string
        modifiedOn:
          format: date-time
          type: string
        modifiedBy:
          type: string
  securitySchemes:
    access_token:
      type: apiKey
      description: Token used to access storefront API.
      name: access_token
      in: query