PUT api/UniqueOffers

Update UniqueOffer

Request Information

URI Parameters

None.

Body Parameters

The UniqueOffer class

UniqueOffer
NameDescriptionTypeAdditional information
Id

GUID Id for UniqueOffer. Assigned by system on Create. [REQUIRED]

globally unique identifier

None.

OfferId

The OfferId for the Offer. [NULLABLE]

globally unique identifier

None.

ConsumerId

The ConsumerId for the Consumer. [NULLABLE]

globally unique identifier

None.

BarcodeId

The BarcodeId for the Barcode. [NULLABLE]

globally unique identifier

None.

Discount

The OfferReward Reward. [NULL]

string

String length: inclusive between 0 and 255

ShareDiscount

The OfferReward Reward once the share reward has been earned. [NULL]

string

None.

RedeemDiscount

The OfferReward Reward once the redemption reward has been earned. [NULL]

string

String length: inclusive between 0 and 255

Timestamp

Indicates when the UniqueOffer was created. [NULLABLE]

date

None.

Offer

Gets the Offer using OfferId.

Offer

None.

Consumer

Gets the Consumer using ConsumerId.

Consumer

None.

Barcode

Gets the Bardcode using BarcodeId.

Barcode

None.

Request Formats

application/json, text/json

Sample:
{
  "Id": "1c1260ba-6229-4cb2-abd3-9c8fa138672c",
  "OfferId": "a8d5b407-2770-466a-8696-18fadfa822ab",
  "ConsumerId": "33f192f4-2e13-4748-8b71-24f0c8004fdf",
  "BarcodeId": "a4b29326-8e78-4410-ae05-dbb71eda9d02",
  "Discount": "sample string 2",
  "ShareDiscount": "sample string 3",
  "RedeemDiscount": "sample string 4",
  "Timestamp": "2018-12-12T05:25:10.7227178+00:00",
  "Offer": {
    "$id": "2",
    "Id": "1ce79368-b97f-4045-a805-9defcbadeb36",
    "MerchantId": "b9226f08-a0b5-4410-b4f7-25e6da54f45f",
    "AppId": "db367287-3315-493e-9f60-d50e734b23c7",
    "Type": 0,
    "Reward": "sample string 4",
    "IsRewardBased": true,
    "Name": "sample string 5",
    "Description": "sample string 6",
    "TermsConditions": "sample string 7",
    "Tags": "sample string 8",
    "StartDate": "2018-12-12T05:25:10.7227178+00:00",
    "EndDate": "2018-12-12T05:25:10.7227178+00:00",
    "ExpiryDate": "2018-12-12T05:25:10.7227178+00:00",
    "Limited": true,
    "RedemptionLimit": 10,
    "Share": true,
    "Created": "2018-12-12T05:25:10.7227178+00:00",
    "Deleted": true,
    "Published": true,
    "OfferImage": "sample string 14",
    "Pause": true,
    "Private": true,
    "Merchant": {
      "$id": "3",
      "Id": "1e82f89f-d6f5-4b4f-a383-7c1a908547f6",
      "PlanId": "313ab936-ebed-441f-b93e-e94258bfbf13",
      "StripeToken": "sample string 2",
      "StripeCustomerId": "sample string 3",
      "CompanyName": "sample string 4",
      "UserId": "sample string 5",
      "Active": true,
      "Deleted": true,
      "TimeZone": "sample string 8",
      "User": {
        "$id": "4",
        "Id": "sample string 1",
        "Email": "sample string 2",
        "EmailConfirmed": true,
        "UserName": "sample string 10",
        "FirstName": "sample string 11",
        "LastName": "sample string 12",
        "Address1": "sample string 13",
        "Address2": "sample string 14",
        "City": "sample string 15",
        "State": "sample string 16",
        "Country": "sample string 17",
        "ZipCode": "sample string 18",
        "DateRegistered": "2018-12-12T05:25:10.7227178+00:00",
        "RegistrationCompleted": true,
        "LastLogin": "2018-12-12T05:25:10.7227178+00:00",
        "TermsConditions": true,
        "MobileNumber": "sample string 21",
        "ProfileImage": "sample string 22",
        "FullName": "sample string 12, sample string 11",
        "Roles": [
          {
            "$id": "5",
            "Id": "sample string 1",
            "Name": "sample string 2",
            "Users": [
              {
                "$ref": "4"
              },
              {
                "$ref": "4"
              }
            ]
          },
          {
            "$ref": "5"
          }
        ]
      },
      "Plan": {
        "$id": "6",
        "Id": "4bd534c0-99fa-4dd0-953c-b54a071cbef8",
        "PlanName": "sample string 2",
        "Description": "sample string 3",
        "LimitedApps": true,
        "AppLimit": 1,
        "LimitedLocations": true,
        "LocationLimit": 1,
        "LimitedOffers": true,
        "OfferLimit": 1,
        "Amount": 1,
        "WithCall": true,
        "SortNo": 8,
        "Billable": true
      },
      "MerchantLocations": [
        {
          "$id": "7",
          "Id": "9586856d-6de0-49fa-a783-86c33279905d",
          "MerchantId": "8e38b108-1db9-4c61-b0fb-ec2b38efac3f",
          "Active": true,
          "Name": "sample string 4",
          "Address1": "sample string 5",
          "Address2": "sample string 6",
          "City": "sample string 7",
          "State": "sample string 8",
          "ZipCode": "sample string 9",
          "PhoneNumber": "sample string 10",
          "Deleted": true,
          "Main": true,
          "Latitude": 1.1,
          "Longitude": 1.1,
          "GeoLocation": null,
          "GeoSpot": true,
          "StoreLocationId": "sample string 14",
          "Merchant": {
            "$ref": "3"
          },
          "CompleteAddress": "sample string 5, sample string 6, sample string 7, sample string 8, sample string 9"
        },
        {
          "$ref": "7"
        }
      ]
    },
    "App": {
      "$id": "8",
      "Id": "fea47b63-d2a0-47c7-940d-63057f254962",
      "MerchantId": "7df546e7-3023-4727-97fb-30fdc367784c",
      "KeyId": "5989d4f9-33ec-4cfe-9bea-641b4bd4d02b",
      "Name": "sample string 4",
      "Description": "sample string 5",
      "Created": "2018-12-12T05:25:10.7227178+00:00",
      "Modified": "2018-12-12T05:25:10.7227178+00:00",
      "Photo": "sample string 7",
      "Deleted": true,
      "Merchant": {
        "$ref": "3"
      },
      "Key": {
        "$id": "9",
        "Id": "b58a252f-074b-448e-9cd6-693ddf72280a",
        "MerchantId": "1a7a2644-7dd6-43af-8374-433717ec81f1",
        "Name": "sample string 3",
        "SecretKey": "sample string 4",
        "Created": "2018-12-12T05:25:10.7227178+00:00",
        "Deleted": true,
        "Assigned": true,
        "Merchant": {
          "$ref": "3"
        }
      }
    },
    "Shares": [
      {
        "$id": "10",
        "Id": "d88ad994-5c11-4033-b70c-9e8973145e74",
        "FromConsumerId": "06b78d16-87e4-40c8-8c61-aac95071f4ff",
        "ToConsumerId": "cc691cf9-081e-457f-860c-27ecdc50a69e",
        "OfferId": "e79501ab-1a4b-4d7f-bb34-0352bab8af1a",
        "Redeemed": true,
        "Timestamp": "2018-12-12T05:25:10.7227178+00:00",
        "ReceiptImage": "sample string 4",
        "TotalAmount": "sample string 5",
        "RedeemedOn": "2018-12-12T05:25:10.7227178+00:00",
        "MerchantLocationId": "071f05b4-4c9c-48de-87f9-9fe126534242",
        "UserName": "sample string 6",
        "Consumer": {
          "$id": "11",
          "Id": "9cc54c8d-77bf-4707-95cb-b766744e18b9",
          "Gender": "sample string 2",
          "Address1": "sample string 3",
          "Address2": "sample string 4",
          "City": "sample string 5",
          "State": "sample string 6",
          "ZipCode": "sample string 7",
          "Image": "sample string 8",
          "Deleted": true
        },
        "Consumer1": {
          "$ref": "11"
        },
        "Offer": {
          "$ref": "2"
        }
      },
      {
        "$ref": "10"
      }
    ]
  },
  "Consumer": {
    "$ref": "11"
  },
  "Barcode": {
    "$id": "12",
    "Id": "411ebbfe-0435-48f5-ba7a-43e35a398d6c",
    "Type": 1,
    "Code": "sample string 2",
    "Deleted": true
  }
}

application/xml

Sample:

An exception has occurred while using the formatter 'XmlMediaTypeFormatter' to generate sample for media type 'application/xml'. Exception message: Object graph for type 'System.Collections.Generic.List`1[[FaceOffers.Entities.UniqueOffer, FaceOffers.Entities, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]]' contains cycles and cannot be serialized if reference tracking is disabled.

text/xml

Sample:

An exception has occurred while using the formatter 'XmlMediaTypeFormatter' to generate sample for media type 'text/xml'. Exception message: Object graph for type 'System.Collections.Generic.List`1[[FaceOffers.Entities.UniqueOffer, FaceOffers.Entities, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]]' contains cycles and cannot be serialized if reference tracking is disabled.

application/x-www-form-urlencoded

Sample:

Failed to generate the sample for media type 'application/x-www-form-urlencoded'. Cannot use formatter 'JQueryMvcFormUrlEncodedFormatter' to write type 'UniqueOffer'.

Response Information

Resource Description

Returns a UniqueOffer

UniqueOffer
NameDescriptionTypeAdditional information
Id

GUID Id for UniqueOffer. Assigned by system on Create. [REQUIRED]

globally unique identifier

None.

OfferId

The OfferId for the Offer. [NULLABLE]

globally unique identifier

None.

ConsumerId

The ConsumerId for the Consumer. [NULLABLE]

globally unique identifier

None.

BarcodeId

The BarcodeId for the Barcode. [NULLABLE]

globally unique identifier

None.

Discount

The OfferReward Reward. [NULL]

string

String length: inclusive between 0 and 255

ShareDiscount

The OfferReward Reward once the share reward has been earned. [NULL]

string

None.

RedeemDiscount

The OfferReward Reward once the redemption reward has been earned. [NULL]

string

String length: inclusive between 0 and 255

Timestamp

Indicates when the UniqueOffer was created. [NULLABLE]

date

None.

Offer

Gets the Offer using OfferId.

Offer

None.

Consumer

Gets the Consumer using ConsumerId.

Consumer

None.

Barcode

Gets the Bardcode using BarcodeId.

Barcode

None.

Response Formats

application/json, text/json

Sample:
{
  "Id": "7b5bb66d-7dc5-4d3d-ba16-97e8c0de7904",
  "OfferId": "9c09c99f-8e71-4fd2-91f8-b6f0a5c81d6c",
  "ConsumerId": "94341210-886c-4922-b440-501fccc3d18a",
  "BarcodeId": "e2574daa-e664-480b-99df-f1e8afa9776a",
  "Discount": "sample string 2",
  "ShareDiscount": "sample string 3",
  "RedeemDiscount": "sample string 4",
  "Timestamp": "2018-12-12T05:25:10.8833586+00:00",
  "Offer": {
    "$id": "2",
    "Id": "c305d9c9-9dff-4392-8814-065ae085d8f4",
    "MerchantId": "71178e01-c59b-4a67-9291-c1dfa0108286",
    "AppId": "f00a1984-7d64-4005-92bb-01c75098b41e",
    "Type": 0,
    "Reward": "sample string 4",
    "IsRewardBased": true,
    "Name": "sample string 5",
    "Description": "sample string 6",
    "TermsConditions": "sample string 7",
    "Tags": "sample string 8",
    "StartDate": "2018-12-12T05:25:10.8833586+00:00",
    "EndDate": "2018-12-12T05:25:10.8833586+00:00",
    "ExpiryDate": "2018-12-12T05:25:10.8833586+00:00",
    "Limited": true,
    "RedemptionLimit": 10,
    "Share": true,
    "Created": "2018-12-12T05:25:10.8833586+00:00",
    "Deleted": true,
    "Published": true,
    "OfferImage": "sample string 14",
    "Pause": true,
    "Private": true,
    "Merchant": {
      "$id": "3",
      "Id": "572688de-4c83-4c4e-8693-6a8b740ab68e",
      "PlanId": "94761eca-5cf3-4ce4-8783-4ff2400bbc3d",
      "StripeToken": "sample string 2",
      "StripeCustomerId": "sample string 3",
      "CompanyName": "sample string 4",
      "UserId": "sample string 5",
      "Active": true,
      "Deleted": true,
      "TimeZone": "sample string 8",
      "User": {
        "$id": "4",
        "Id": "sample string 1",
        "Email": "sample string 2",
        "EmailConfirmed": true,
        "UserName": "sample string 10",
        "FirstName": "sample string 11",
        "LastName": "sample string 12",
        "Address1": "sample string 13",
        "Address2": "sample string 14",
        "City": "sample string 15",
        "State": "sample string 16",
        "Country": "sample string 17",
        "ZipCode": "sample string 18",
        "DateRegistered": "2018-12-12T05:25:10.8833586+00:00",
        "RegistrationCompleted": true,
        "LastLogin": "2018-12-12T05:25:10.8833586+00:00",
        "TermsConditions": true,
        "MobileNumber": "sample string 21",
        "ProfileImage": "sample string 22",
        "FullName": "sample string 12, sample string 11",
        "Roles": [
          {
            "$id": "5",
            "Id": "sample string 1",
            "Name": "sample string 2",
            "Users": [
              {
                "$ref": "4"
              },
              {
                "$ref": "4"
              }
            ]
          },
          {
            "$ref": "5"
          }
        ]
      },
      "Plan": {
        "$id": "6",
        "Id": "ac956ec8-b5cf-4d47-9e09-a57c5b9eb116",
        "PlanName": "sample string 2",
        "Description": "sample string 3",
        "LimitedApps": true,
        "AppLimit": 1,
        "LimitedLocations": true,
        "LocationLimit": 1,
        "LimitedOffers": true,
        "OfferLimit": 1,
        "Amount": 1,
        "WithCall": true,
        "SortNo": 8,
        "Billable": true
      },
      "MerchantLocations": [
        {
          "$id": "7",
          "Id": "fb703d21-e97c-45a5-8f71-de43d732fab1",
          "MerchantId": "987e2adb-c286-4860-8d38-5bc06b2437cb",
          "Active": true,
          "Name": "sample string 4",
          "Address1": "sample string 5",
          "Address2": "sample string 6",
          "City": "sample string 7",
          "State": "sample string 8",
          "ZipCode": "sample string 9",
          "PhoneNumber": "sample string 10",
          "Deleted": true,
          "Main": true,
          "Latitude": 1.1,
          "Longitude": 1.1,
          "GeoLocation": null,
          "GeoSpot": true,
          "StoreLocationId": "sample string 14",
          "Merchant": {
            "$ref": "3"
          },
          "CompleteAddress": "sample string 5, sample string 6, sample string 7, sample string 8, sample string 9"
        },
        {
          "$ref": "7"
        }
      ]
    },
    "App": {
      "$id": "8",
      "Id": "dad80c11-43de-46df-a4ab-62e9115c5989",
      "MerchantId": "43e66498-7988-4b75-830d-5a42e1e337cd",
      "KeyId": "dece298d-c690-437b-a387-2d0ae5d01bb1",
      "Name": "sample string 4",
      "Description": "sample string 5",
      "Created": "2018-12-12T05:25:10.8833586+00:00",
      "Modified": "2018-12-12T05:25:10.8833586+00:00",
      "Photo": "sample string 7",
      "Deleted": true,
      "Merchant": {
        "$ref": "3"
      },
      "Key": {
        "$id": "9",
        "Id": "ee68f679-f7ae-46f4-bf18-ee9abaa1ecd2",
        "MerchantId": "0d5f408f-b71b-4511-aed1-c192fe028132",
        "Name": "sample string 3",
        "SecretKey": "sample string 4",
        "Created": "2018-12-12T05:25:10.8833586+00:00",
        "Deleted": true,
        "Assigned": true,
        "Merchant": {
          "$ref": "3"
        }
      }
    },
    "Shares": [
      {
        "$id": "10",
        "Id": "d7ef02bb-4bfa-417a-95b8-547d6d8c3622",
        "FromConsumerId": "9eae1dd0-604b-4fe7-a716-a6c3f937f381",
        "ToConsumerId": "3e1fc23e-ad28-43fd-a45e-d60b900774f6",
        "OfferId": "52257a89-c402-4d7c-9800-a732233ed56a",
        "Redeemed": true,
        "Timestamp": "2018-12-12T05:25:10.8833586+00:00",
        "ReceiptImage": "sample string 4",
        "TotalAmount": "sample string 5",
        "RedeemedOn": "2018-12-12T05:25:10.8833586+00:00",
        "MerchantLocationId": "43e29c3c-b5cb-44e1-8e27-a6d960a425bc",
        "UserName": "sample string 6",
        "Consumer": {
          "$id": "11",
          "Id": "5a6d6f58-705e-4aed-9926-5c5d49a37459",
          "Gender": "sample string 2",
          "Address1": "sample string 3",
          "Address2": "sample string 4",
          "City": "sample string 5",
          "State": "sample string 6",
          "ZipCode": "sample string 7",
          "Image": "sample string 8",
          "Deleted": true
        },
        "Consumer1": {
          "$ref": "11"
        },
        "Offer": {
          "$ref": "2"
        }
      },
      {
        "$ref": "10"
      }
    ]
  },
  "Consumer": {
    "$ref": "11"
  },
  "Barcode": {
    "$id": "12",
    "Id": "41d22691-f0d7-4852-87eb-83b8d4cdbab9",
    "Type": 1,
    "Code": "sample string 2",
    "Deleted": true
  }
}

application/xml

Sample:

An exception has occurred while using the formatter 'XmlMediaTypeFormatter' to generate sample for media type 'application/xml'. Exception message: Object graph for type 'System.Collections.Generic.List`1[[FaceOffers.Entities.UniqueOffer, FaceOffers.Entities, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]]' contains cycles and cannot be serialized if reference tracking is disabled.

text/xml

Sample:

An exception has occurred while using the formatter 'XmlMediaTypeFormatter' to generate sample for media type 'text/xml'. Exception message: Object graph for type 'System.Collections.Generic.List`1[[FaceOffers.Entities.UniqueOffer, FaceOffers.Entities, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]]' contains cycles and cannot be serialized if reference tracking is disabled.