Create a Subscription Invoice

The last step of the partner API process is to create an invoice for the created period. This provides Riverty with the required invoice details and kickstarts the invoicing process. With the provided information, Riverty will generate the invoice and distribute it to the customer. For more information see Invoice Process. Periods can only be invoiced between the start & end date of each period.

The invoice amount needs to be equal to the period price set in the Create a Subscription Period operation.

It is the responsibility of the merchant/partner to raise invoices for each of the created periods. If a subscription period has passed its end date and an invoice has not been sent, Riverty will chargeback the financed period price.

POST {{PFBaseURL}}/v1/clients/{{ClientID}}/partner-subscriptions/{{PartnerSubscriptionID}}/invoices

  • ClientID = Your Riverty client_id
  • PartnerSubscriptionID = The subscription ID

Subscription Invoice Call Example

{
  "periodId": "{{SubscriptionPeriodID}}",
  "invoiceLines": [
    {
      "productId": "{{SubscriptionID}}",
      "description": "string",
      "imageUrl": "string",
      "grossAmount": 100,
      "vatPercentage": 50,
      "unit": {
        "netPrice": 100,
        "quantity": 1,
        "code": "NOK"
      },
      "metadata": [
        {
          "key": "metadata key",
          "value": "metadata value"
        }
      ]
    }
  ],
  "metadata": [
    {
      "key": "metadata key",
      "value": "metadata value"
    }
  ]
}

Subscription Invoice Response Example

{
  "invoiceNumber": "PF100002"
}