POST api/Consumers/Account

Create ConsumerAccount

Request Information

URI Parameters

None.

Body Parameters

The ConsumerAccountViewModel

ConsumerAccountViewModel
NameDescriptionTypeAdditional information
Consumer

Consumer

None.

MerchantConsumer

MerchantConsumer

None.

Request Formats

application/json, text/json

Sample:
{
  "Consumer": {
    "$id": "2",
    "Id": "b1d21bb1-d64e-4fba-b443-dca59e3d0543",
    "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
  },
  "MerchantConsumer": {
    "$id": "3",
    "Id": "3dc55a44-21d2-4fbc-b426-a6ea5cb6c854",
    "ConsumerId": "81c39b81-ab81-4381-8ec4-a3aa7ee2e6e2",
    "MerchantId": "0c642071-8e88-422c-89d5-8642c1868965",
    "MerchantLocationId": "caf65cc6-b3a0-40d4-a8a2-3b09109a731e",
    "Email": "sample string 5",
    "PhoneNumber": "sample string 6",
    "FirstName": "sample string 7",
    "LastName": "sample string 8",
    "Deleted": true,
    "EmailOptIn": true,
    "PhoneOptIn": true,
    "FullName": "sample string 8, sample string 7",
    "Consumer": {
      "$ref": "2"
    },
    "Merchant": {
      "$id": "4",
      "Id": "fa1fe9bb-9bdb-499b-bfb2-69847af43ced",
      "PlanId": "3d6f16d1-b5fc-4880-91f4-7e11b4a57a86",
      "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": "5",
        "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-09-21T18:32:31.8924197+00:00",
        "RegistrationCompleted": true,
        "LastLogin": "2018-09-21T18:32:31.8924197+00:00",
        "TermsConditions": true,
        "MobileNumber": "sample string 21",
        "ProfileImage": "sample string 22",
        "FullName": "sample string 12, sample string 11",
        "Roles": [
          {
            "$id": "6",
            "Id": "sample string 1",
            "Name": "sample string 2",
            "Users": [
              {
                "$ref": "5"
              },
              {
                "$ref": "5"
              }
            ]
          },
          {
            "$ref": "6"
          }
        ]
      },
      "Plan": {
        "$id": "7",
        "Id": "0680b2d9-2eec-4611-b250-cb0761c4652c",
        "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": "8",
          "Id": "8c467f1e-4a28-44cc-b298-669285ba9c9d",
          "MerchantId": "e1862a75-1030-483d-a6b0-fdda08a46c5e",
          "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,
          "Merchant": {
            "$ref": "4"
          },
          "CompleteAddress": "sample string 5, sample string 6, sample string 7, sample string 8, sample string 9"
        },
        {
          "$ref": "8"
        }
      ]
    },
    "MerchantLocation": {
      "$ref": "8"
    }
  }
}

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.MerchantConsumer, 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.MerchantConsumer, 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 'ConsumerAccountViewModel'.

Response Information

Resource Description

Returns a MerchantConsumer

ConsumerAccountViewModel
NameDescriptionTypeAdditional information
Consumer

Consumer

None.

MerchantConsumer

MerchantConsumer

None.

Response Formats

application/json, text/json

Sample:
{
  "Consumer": {
    "$id": "2",
    "Id": "bed62b9c-0e1c-490f-b35a-02fa55fa5ea8",
    "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
  },
  "MerchantConsumer": {
    "$id": "3",
    "Id": "afdab2d7-7bba-4cb3-90e9-25ec818bc1a8",
    "ConsumerId": "66ef1f53-6fd9-4419-9040-dcf470255427",
    "MerchantId": "6efb369f-9168-4f4c-b037-347b2fd94bec",
    "MerchantLocationId": "7b43ad68-52ea-4b33-a8f5-f26c6a38d1b1",
    "Email": "sample string 5",
    "PhoneNumber": "sample string 6",
    "FirstName": "sample string 7",
    "LastName": "sample string 8",
    "Deleted": true,
    "EmailOptIn": true,
    "PhoneOptIn": true,
    "FullName": "sample string 8, sample string 7",
    "Consumer": {
      "$ref": "2"
    },
    "Merchant": {
      "$id": "4",
      "Id": "07e5320e-3c0f-48e6-aa5f-eabc9440884f",
      "PlanId": "9a4a2be3-a2f0-4321-93a2-0e0b1797a96c",
      "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": "5",
        "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-09-21T18:32:32.0173651+00:00",
        "RegistrationCompleted": true,
        "LastLogin": "2018-09-21T18:32:32.0173651+00:00",
        "TermsConditions": true,
        "MobileNumber": "sample string 21",
        "ProfileImage": "sample string 22",
        "FullName": "sample string 12, sample string 11",
        "Roles": [
          {
            "$id": "6",
            "Id": "sample string 1",
            "Name": "sample string 2",
            "Users": [
              {
                "$ref": "5"
              },
              {
                "$ref": "5"
              }
            ]
          },
          {
            "$ref": "6"
          }
        ]
      },
      "Plan": {
        "$id": "7",
        "Id": "11a1e315-ac21-4d5d-a474-13e21b3607ee",
        "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": "8",
          "Id": "a5552f69-cb40-43da-a192-8be092ac13e3",
          "MerchantId": "0cd056d2-71a3-465d-b0ed-7bdcc41bdaef",
          "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,
          "Merchant": {
            "$ref": "4"
          },
          "CompleteAddress": "sample string 5, sample string 6, sample string 7, sample string 8, sample string 9"
        },
        {
          "$ref": "8"
        }
      ]
    },
    "MerchantLocation": {
      "$ref": "8"
    }
  }
}

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.MerchantConsumer, 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.MerchantConsumer, FaceOffers.Entities, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]]' contains cycles and cannot be serialized if reference tracking is disabled.