---
agentTools:
  projectIndex: https://finrock.readme.io/llms.txt
---

# Create Invoice

creates a new invoice with a disposable crypto address

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "Prod",
    "version": "1.0"
  },
  "servers": [
    {
      "url": "https://api.finrock.io"
    }
  ],
  "security": [
    {}
  ],
  "paths": {
    "/dac/v1/create-invoice": {
      "post": {
        "summary": "Create Invoice",
        "description": "creates a new invoice with a disposable crypto address",
        "operationId": "create-invoice",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "crypto",
                  "memo"
                ],
                "properties": {
                  "crypto": {
                    "type": "object",
                    "description": "crypto details",
                    "required": [
                      "asset_id"
                    ],
                    "properties": {
                      "asset_id": {
                        "type": "string",
                        "description": "finrock asset id",
                        "default": "BTC"
                      },
                      "amount": {
                        "type": "number",
                        "description": "the value in crypto currency",
                        "format": "double"
                      }
                    }
                  },
                  "fiat": {
                    "type": "object",
                    "description": "fiat estimation (if required)",
                    "properties": {
                      "asset_id": {
                        "type": "string",
                        "description": "fiat currency (e.g. USD, GBP)",
                        "default": "GBP"
                      },
                      "amount": {
                        "type": "number",
                        "format": "double"
                      }
                    }
                  },
                  "memo": {
                    "type": "string",
                    "description": "a descriptive note for this payment."
                  },
                  "payer": {
                    "type": "object",
                    "description": "sender's details",
                    "required": [
                      "name",
                      "email"
                    ],
                    "properties": {
                      "name": {
                        "type": "string",
                        "description": "John Doe"
                      },
                      "email": {
                        "type": "string"
                      },
                      "mobile": {
                        "type": "string",
                        "description": "phone number with country code"
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "200",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{\n  \"fiat\": {\n    \"asset_id\": \"AED\",\n    \"asset\": \"AED\",\n    \"symbol\": \"د.إ\",\n    \"asset_name\": \"Emirati Dirham\",\n    \"amount\": 172.53,\n    \"paid\": 0,\n    \"pending\": 172.53\n  },\n  \"crypto\": {\n    \"asset_id\": \"ETH_TEST\",\n    \"asset\": \"ETH\",\n    \"network\": \"\",\n    \"asset_name\": \"Ethereum Testnet\",\n    \"icon\": \"https://finrock.io/assets/icons/coins/ETH.png\",\n    \"network_icon\": \"https://finrock.io/assets/icons/coins/ETH.png\",\n    \"amount\": 0.01,\n    \"paid\": 0,\n    \"pending\": 0.01,\n    \"address\": \"0x73c7030015F3cB8D905e6982f44576615a646eA0\",\n    \"address_tag\": \"\",\n    \"testnet\": true,\n    \"address_url\": \"https://etherscan.io/address/0x73c7030015F3cB8D905e6982f44576615a646eA0\"\n  },\n  \"memo\": \"Fried Rice\",\n  \"payer\": {\n    \"name\": null,\n    \"email\": null,\n    \"mobile\": null,\n    \"country_code\": null,\n    \"ip\": null,\n    \"browser\": null,\n    \"os\": null\n  },\n  \"company\": {\n    \"name\": \"Tesco Retails Ltd.\",\n    \"email\": \"demo@store.co.uk\",\n    \"country_code\": \"GB\"\n  },\n  \"id\": \"91eb7310-80c2-47a5-a557-ec74e41176bb\",\n  \"expiry_ts\": 1755086992,\n  \"status\": \"Pending\",\n  \"txn_hash\": null,\n  \"explorer_url\": null,\n  \"payment_url\": \"https://finrock.io/wpay/91eb7310-80c2-47a5-a557-ec74e41176bb\",\n  \"ipn_url\": \"https://webhook.site/0d4311ac-f32a-4c1c-8854-4baebffead0b\",\n  \"success_url\": \"https://finrock.io/success\",\n  \"failed_url\": \"https://finrock.io/failed\",\n  \"confirmations\": \"0/5\",\n  \"txns\": []\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "fiat": {
                      "type": "object",
                      "properties": {
                        "asset_id": {
                          "type": "string",
                          "example": "AED"
                        },
                        "asset": {
                          "type": "string",
                          "example": "AED"
                        },
                        "symbol": {
                          "type": "string",
                          "example": "د.إ"
                        },
                        "asset_name": {
                          "type": "string",
                          "example": "Emirati Dirham"
                        },
                        "amount": {
                          "type": "number",
                          "example": 172.53,
                          "default": 0
                        },
                        "paid": {
                          "type": "integer",
                          "example": 0,
                          "default": 0
                        },
                        "pending": {
                          "type": "number",
                          "example": 172.53,
                          "default": 0
                        }
                      }
                    },
                    "crypto": {
                      "type": "object",
                      "properties": {
                        "asset_id": {
                          "type": "string",
                          "example": "ETH_TEST"
                        },
                        "asset": {
                          "type": "string",
                          "example": "ETH"
                        },
                        "network": {
                          "type": "string",
                          "example": ""
                        },
                        "asset_name": {
                          "type": "string",
                          "example": "Ethereum Testnet"
                        },
                        "icon": {
                          "type": "string",
                          "example": "https://finrock.io/assets/icons/coins/ETH.png"
                        },
                        "network_icon": {
                          "type": "string",
                          "example": "https://finrock.io/assets/icons/coins/ETH.png"
                        },
                        "amount": {
                          "type": "number",
                          "example": 0.01,
                          "default": 0
                        },
                        "paid": {
                          "type": "integer",
                          "example": 0,
                          "default": 0
                        },
                        "pending": {
                          "type": "number",
                          "example": 0.01,
                          "default": 0
                        },
                        "address": {
                          "type": "string",
                          "example": "0x73c7030015F3cB8D905e6982f44576615a646eA0"
                        },
                        "address_tag": {
                          "type": "string",
                          "example": ""
                        },
                        "testnet": {
                          "type": "boolean",
                          "example": true,
                          "default": true
                        },
                        "address_url": {
                          "type": "string",
                          "example": "https://etherscan.io/address/0x73c7030015F3cB8D905e6982f44576615a646eA0"
                        }
                      }
                    },
                    "memo": {
                      "type": "string",
                      "example": "Fried Rice"
                    },
                    "payer": {
                      "type": "object",
                      "properties": {
                        "name": {},
                        "email": {},
                        "mobile": {},
                        "country_code": {},
                        "ip": {},
                        "browser": {},
                        "os": {}
                      }
                    },
                    "company": {
                      "type": "object",
                      "properties": {
                        "name": {
                          "type": "string",
                          "example": "Tesco Retails Ltd."
                        },
                        "email": {
                          "type": "string",
                          "example": "demo@store.co.uk"
                        },
                        "country_code": {
                          "type": "string",
                          "example": "GB"
                        }
                      }
                    },
                    "id": {
                      "type": "string",
                      "example": "91eb7310-80c2-47a5-a557-ec74e41176bb"
                    },
                    "expiry_ts": {
                      "type": "integer",
                      "example": 1755086992,
                      "default": 0
                    },
                    "status": {
                      "type": "string",
                      "example": "Pending"
                    },
                    "txn_hash": {},
                    "explorer_url": {},
                    "payment_url": {
                      "type": "string",
                      "example": "https://finrock.io/wpay/91eb7310-80c2-47a5-a557-ec74e41176bb"
                    },
                    "ipn_url": {
                      "type": "string",
                      "example": "https://webhook.site/0d4311ac-f32a-4c1c-8854-4baebffead0b"
                    },
                    "success_url": {
                      "type": "string",
                      "example": "https://finrock.io/success"
                    },
                    "failed_url": {
                      "type": "string",
                      "example": "https://finrock.io/failed"
                    },
                    "confirmations": {
                      "type": "string",
                      "example": "0/5"
                    },
                    "txns": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {}
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "400",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {}
                }
              }
            }
          }
        },
        "deprecated": false,
        "x-readme": {
          "code-samples": [
            {
              "language": "text",
              "code": "{\n    \"fiat\": {\n        \"asset_id\": \"AED\",\n        \"amount\": 172.53\n    },\n    \"crypto\": {\n        \"asset_id\": \"ETH_TEST\"\n    },\n    \"memo\": \"inv0001\",\n    \"payer\": {\n        \"name\": \"John Doe\",\n        \"email\": \"john@mailinator.com\",\n        \"mobile\": \"+447656126112\"\n    }\n}"
            }
          ],
          "samples-languages": [
            "text"
          ]
        }
      }
    }
  },
  "x-readme": {
    "headers": [],
    "explorer-enabled": true,
    "proxy-enabled": true
  },
  "x-readme-fauxas": true,
  "_id": "61ec7ec6c85949003bb883dc:689c33b642059271c6568f70"
}
```