POST api/payments/iyzico

Request Information

URI Parameters

None.

Body Parameters

CreateOrderRequest
NameDescriptionTypeAdditional information
Description

string

None.

RejectionReason

integer

None.

OrderType

integer

None.

Address

AddressDto

None.

Customer

CustomerDto

None.

Store

StoreDto

None.

Products

Collection of ProductDto

None.

Payment

PaymentDto

None.

Card

CardDto

None.

Promotion

PromotionDto

None.

Request Formats

application/json, text/json

Sample:
{
  "Description": "sample string 1",
  "RejectionReason": 1,
  "OrderType": 2,
  "Address": {
    "Address": "sample string 1",
    "AddressDescription": "sample string 2",
    "City": "sample string 3",
    "District": "sample string 4",
    "ApartmentNumber": "sample string 5",
    "DoorNumber": "sample string 6",
    "Floor": "sample string 7",
    "AddressLat": "sample string 8",
    "AddressLng": "sample string 9"
  },
  "Customer": {
    "CustomerId": 1,
    "CustomerSessionId": "sample string 2",
    "CustomerFirstName": "sample string 3",
    "CustomerLastName": "sample string 4",
    "CustomerPhone": "sample string 5",
    "CustomerEmail": "sample string 6",
    "CustomerNote": "sample string 7",
    "DoNotKnock": true,
    "DropOffAtDoor": true,
    "IsEcoFriendly": true
  },
  "Store": {
    "DeliveryProvider": 1,
    "StoreId": 2,
    "GroupId": 3
  },
  "Products": [
    {
      "ProductId": 1,
      "Price": 2.0,
      "TotalPrice": 3.0,
      "Quantity": 4,
      "Note": "sample string 5",
      "ProductName": "sample string 6",
      "OptionCategories": [
        {
          "OrderOptionId": 1,
          "OrderOptionItemID": 2,
          "Price": 3.0
        },
        {
          "OrderOptionId": 1,
          "OrderOptionItemID": 2,
          "Price": 3.0
        }
      ]
    },
    {
      "ProductId": 1,
      "Price": 2.0,
      "TotalPrice": 3.0,
      "Quantity": 4,
      "Note": "sample string 5",
      "ProductName": "sample string 6",
      "OptionCategories": [
        {
          "OrderOptionId": 1,
          "OrderOptionItemID": 2,
          "Price": 3.0
        },
        {
          "OrderOptionId": 1,
          "OrderOptionItemID": 2,
          "Price": 3.0
        }
      ]
    }
  ],
  "Payment": {
    "PaymentId": 1,
    "TotalPrice": 2.0,
    "CouponId": 3,
    "CouponCode": "sample string 4",
    "Discount": 5.0,
    "DiscountedPrice": 6.0,
    "StoreDiscounted": 7.0,
    "AppDiscounted": 8.0,
    "DeliveryFee": 9.0,
    "ServiceFee": 10.0
  },
  "Card": {
    "orderChannel": "sample string 1",
    "cardName": "sample string 2",
    "cardNumber": "sample string 3",
    "cardDate": "sample string 4",
    "cardCvv": "sample string 5",
    "usingSaved": true,
    "savedCardId": 1,
    "saveCard": true,
    "saveCardAlias": "sample string 8"
  },
  "Promotion": {
    "PromoId": 1,
    "PromoCode": "sample string 2",
    "DiscountType": 3,
    "DiscountRate": 4.0,
    "MinBasketPrice": 5.0,
    "DiscountAmount": 6.0,
    "Title": "sample string 7",
    "Source": "sample string 8"
  }
}

application/xml, text/xml

Sample:
<OrdersViewModel.CreateOrderRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/HizirYetisAPI.ViewModels">
  <Address>
    <Address>sample string 1</Address>
    <AddressDescription>sample string 2</AddressDescription>
    <AddressLat>sample string 8</AddressLat>
    <AddressLng>sample string 9</AddressLng>
    <ApartmentNumber>sample string 5</ApartmentNumber>
    <City>sample string 3</City>
    <District>sample string 4</District>
    <DoorNumber>sample string 6</DoorNumber>
    <Floor>sample string 7</Floor>
  </Address>
  <Card>
    <cardCvv>sample string 5</cardCvv>
    <cardDate>sample string 4</cardDate>
    <cardName>sample string 2</cardName>
    <cardNumber>sample string 3</cardNumber>
    <orderChannel>sample string 1</orderChannel>
    <saveCard>true</saveCard>
    <saveCardAlias>sample string 8</saveCardAlias>
    <savedCardId>1</savedCardId>
    <usingSaved>true</usingSaved>
  </Card>
  <Customer>
    <CustomerEmail>sample string 6</CustomerEmail>
    <CustomerFirstName>sample string 3</CustomerFirstName>
    <CustomerId>1</CustomerId>
    <CustomerLastName>sample string 4</CustomerLastName>
    <CustomerNote>sample string 7</CustomerNote>
    <CustomerPhone>sample string 5</CustomerPhone>
    <CustomerSessionId>sample string 2</CustomerSessionId>
    <DoNotKnock>true</DoNotKnock>
    <DropOffAtDoor>true</DropOffAtDoor>
    <IsEcoFriendly>true</IsEcoFriendly>
  </Customer>
  <Description>sample string 1</Description>
  <OrderType>2</OrderType>
  <Payment>
    <AppDiscounted>8</AppDiscounted>
    <CouponCode>sample string 4</CouponCode>
    <CouponId>3</CouponId>
    <DeliveryFee>9</DeliveryFee>
    <Discount>5</Discount>
    <DiscountedPrice>6</DiscountedPrice>
    <PaymentId>1</PaymentId>
    <ServiceFee>10</ServiceFee>
    <StoreDiscounted>7</StoreDiscounted>
    <TotalPrice>2</TotalPrice>
  </Payment>
  <Products>
    <OrdersViewModel.ProductDto>
      <Note>sample string 5</Note>
      <OptionCategories>
        <OrdersViewModel.OptionCategoryDto>
          <OrderOptionId>1</OrderOptionId>
          <OrderOptionItemID>2</OrderOptionItemID>
          <Price>3</Price>
        </OrdersViewModel.OptionCategoryDto>
        <OrdersViewModel.OptionCategoryDto>
          <OrderOptionId>1</OrderOptionId>
          <OrderOptionItemID>2</OrderOptionItemID>
          <Price>3</Price>
        </OrdersViewModel.OptionCategoryDto>
      </OptionCategories>
      <Price>2</Price>
      <ProductId>1</ProductId>
      <ProductName>sample string 6</ProductName>
      <Quantity>4</Quantity>
      <TotalPrice>3</TotalPrice>
    </OrdersViewModel.ProductDto>
    <OrdersViewModel.ProductDto>
      <Note>sample string 5</Note>
      <OptionCategories>
        <OrdersViewModel.OptionCategoryDto>
          <OrderOptionId>1</OrderOptionId>
          <OrderOptionItemID>2</OrderOptionItemID>
          <Price>3</Price>
        </OrdersViewModel.OptionCategoryDto>
        <OrdersViewModel.OptionCategoryDto>
          <OrderOptionId>1</OrderOptionId>
          <OrderOptionItemID>2</OrderOptionItemID>
          <Price>3</Price>
        </OrdersViewModel.OptionCategoryDto>
      </OptionCategories>
      <Price>2</Price>
      <ProductId>1</ProductId>
      <ProductName>sample string 6</ProductName>
      <Quantity>4</Quantity>
      <TotalPrice>3</TotalPrice>
    </OrdersViewModel.ProductDto>
  </Products>
  <Promotion>
    <DiscountAmount>6</DiscountAmount>
    <DiscountRate>4</DiscountRate>
    <DiscountType>3</DiscountType>
    <MinBasketPrice>5</MinBasketPrice>
    <PromoCode>sample string 2</PromoCode>
    <PromoId>1</PromoId>
    <Source>sample string 8</Source>
    <Title>sample string 7</Title>
  </Promotion>
  <RejectionReason>1</RejectionReason>
  <Store>
    <DeliveryProvider>1</DeliveryProvider>
    <GroupId>3</GroupId>
    <StoreId>2</StoreId>
  </Store>
</OrdersViewModel.CreateOrderRequest>

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 'CreateOrderRequest'.

Response Information

Resource Description

PaymentResult
NameDescriptionTypeAdditional information
Status

boolean

None.

Content

string

None.

Message

string

None.

Response Formats

application/json, text/json

Sample:
{
  "Status": true,
  "Content": "sample string 2",
  "Message": "sample string 3"
}

application/xml, text/xml

Sample:
<PaymentResult xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/HizirYetisAPI.ViewModels">
  <Content>sample string 2</Content>
  <Message>sample string 3</Message>
  <Status>true</Status>
</PaymentResult>