GetPromotions

This call is to retrieve an array of Promotion objects at the location.

Request Parameters
  • accessToken string — Your access token (passed in SOAP body, not headers).
  • locationToken string — Your location token (passed in SOAP body, not headers).
Response Parameters
  • Message string — Returns a PAR POS Error message if the request did not go through. Otherwise, this field will be null.

  • ResultCode int — Returns one of the following:

    • 0 — Success
    • 1 — Unknown Error
    • 3 — Server Unavailable
    • 4 — Access Denied
  • Promotions Array of Promotion — Array of Promotion objects for this location.

    Promotion Properties
    • Active bool — True if this Promotion is active, False if inactive

    • AlternateId string — Optional alternate identifier for this Promotion

    • CustomFields Array of CustomField — Custom fields associated with this Promotion

      CustomField Properties
      • Id int — Unique Id of this CustomField
      • FieldName string — Name of this CustomField
      • Value string — Value of this CustomField
    • Id int — Unique Id of this Promotion

    • Name string — Name of this Promotion

    • Type PromotionType — Returns one of the following:

      • Bogo
      • OrderReduction
      • Coupon
      • GiftCard
      • Combo
Headers
  • SOAPAction
    Type: string
    required
Body
required
application/json

SOAP envelope containing the GetPromotions request with accessToken and locationToken in body.

Responses
  • text/xml; charset=utf-8
Request Example for post/GetPromotions
cURL
curl --request POST \
  --url 'https://{server_name_goes_here}.parpos.com/Settings.svc?Settings_GetPromotions' \
  --header 'Content-Type: text/xml; charset=utf-8' \
  --header 'SOAPAction: "http://tempuri.org/ISettingsWebService/GetPromotions"' \
  --data '<soapenv:Envelope
    xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
    xmlns:tem="http://tempuri.org/">
    <soapenv:Header/>
    <soapenv:Body>
      <tem:GetPromotions>
        <tem:accessToken>AccessToken</tem:accessToken>
        <tem:locationToken>LocationToken</tem:locationToken>
      </tem:GetPromotions>
    </soapenv:Body>
  </soapenv:Envelope>'
<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
  <s:Body>
    <Settings_GetPromotionsResponse xmlns="http://tempuri.org/">
      <Settings_GetPromotionsResult>
        <Message>Success</Message>
        <ResultCode>0</ResultCode>
        <Promotions>
          <Promotion>
            <Active>true</Active>
            <AlternateId>PROMO-001</AlternateId>
            <CustomFields>
              <CustomField>
                <Id>1</Id>
                <FieldName>Category</FieldName>
                <Value>Special</Value>
              </CustomField>
            </CustomFields>
            <Id>5</Id>
            <Name>Happy Hour</Name>
            <Type>0</Type>
          </Promotion>
        </Promotions>
      </Settings_GetPromotionsResult>
    </Settings_GetPromotionsResponse>
  </s:Body>
</s:Envelope>