# Order details

**POST** `/{phone_number_id}/messages`

Product: [WhatsApp](https://devdocs.pinnacle.in/docs/whatsapp.md)  
Version: [3.0](https://devdocs.pinnacle.in/docs/whatsapp/3-0.md)

Order details from the Partners API documentation.

## Request

URL: `https://partnersv1.pinbot.ai/v3/{phone_number_id}/messages`

Authentication location: `header`

Authentication name: `apikey`

### Request schema


```json
{
  "type": "object",
  "properties": {
    "raw_example": {
      "type": "string"
    }
  }
}
```

### Request example


```json
{
  "raw_example": "{\n\"messaging_product\": \"whatsapp\",\n\n\"to\": \"{{Recipient phone number}}\",\n\"type\": \"interactive\",\n\"recipient_type\": \"individual\",\n\"interactive\": {\n\"type\": \"order_details\",\n\"body\": {\n\"text\": \"Test payment\"\n},\n\"header\": {\n\"type\": \"{{Media-type}}\",\n\"image\": {\n\"link\": \"{{Media-Url}}\"\n}\n},\n\"action\": {\n\"name\": \"review_and_pay\",\n\"parameters\": {\n\"reference_id\": \"EZV2023032712042512044720\",\n\"type\": \"digital-goods\",\n\"currency\": \"INR\",\n\"total_amount\": {\n\"value\": 100,\n\"offset\": 100\n},\n\"payment_settings\": [\n{\n\"type\": \"payment_gateway\",\n\"payment_gateway\": {\n\n\"type\": \"razorpay / payu\",\n\"configuration_name\":\"payment-config-id\"\n}\n}\n]\n\"order\": {\n\"status\": \"pending\",\n\"items\": [\n{\n\"retailer_id\": \"R1\",\n\"product_id\": \"product-id\",\n\"name\": \"Test Payment Rs. 1\",\n\"amount\": {\n\"value\": 100,\n\"offset\": 100\n},\n\"quantity\": 1\n}\n],\n\"subtotal\": {\n\"value\": 100,\n\"offset\": 100\n},\n\"tax\": {\n\"value\": 0,\n\"offset\": 100\n}\n\n}\n}\n},\n\"footer\": {\n\"text\": \"{{text}}\"\n}\n}\n}"
}
```

## Response schema


```json
{
  "type": "object",
  "properties": {
    "raw_example": {
      "type": "string"
    }
  }
}
```

## Response examples


```json
{
  "200": {
    "raw_example": "{\n\"messaging_product\": \"whatsapp\",\n\"contacts\": [\n{\n\"input\": \"9175XXXXXXXX\",\n\"wa_id\": \"9175XXXXXXXX\"\n}\n],\n\"messages\": [\n{\n\"id\":\n\"wamid.HBgMOTE3OTcyODkyNzEyFQIAERgSQzAwRDEzNkQ1NDFFNkM3NkEzAA=\n=\"\n}\n]\n}\n"
  }
}
```

## Status codes


```json
[
  {
    "code": 200,
    "description": "The request was successful."
  },
  {
    "code": 400,
    "description": "Bad request or invalid parameters."
  },
  {
    "code": 401,
    "description": "API key is missing or invalid."
  },
  {
    "code": 403,
    "description": "The request is not authorized for this resource."
  },
  {
    "code": 404,
    "description": "The requested resource was not found."
  },
  {
    "code": 500,
    "description": "The server encountered an error."
  }
]
```
