Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
44 changes: 44 additions & 0 deletions openapi/api.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8380,6 +8380,44 @@ paths:
schema:
"$ref": "#/components/schemas/Error"
x-code-samples: []
post:
tags:
- external_invoices
operationId: create_external_invoice
summary: Create an external invoice
requestBody:
content:
application/json:
schema:
"$ref": "#/components/schemas/ExternalInvoiceCreate"
required: true
responses:
'201':
description: Returns the external invoice
content:
application/json:
schema:
"$ref": "#/components/schemas/ExternalInvoice"
'400':
description: Bad request; perhaps missing or invalid parameters.
content:
application/json:
schema:
"$ref": "#/components/schemas/Error"
'404':
description: External subscription cannot be completed for the specified
reason.
content:
application/json:
schema:
"$ref": "#/components/schemas/Error"
default:
description: Unexpected error.
content:
application/json:
schema:
"$ref": "#/components/schemas/Error"
x-code-samples: []
"/invoices":
get:
tags:
Expand Down Expand Up @@ -18948,6 +18986,12 @@ components:
description: Represents the card network preference associated with the
billing info for dual badged cards. Must be a supported card network.
"$ref": "#/components/schemas/CardNetworkEnum"
return_url:
type: string
title: Return URL
description: Specifies a URL to which a consumer will be redirected upon
completion of a redirect payment flow. Only redirect payment flows operating
through Adyen Components will utilize this return URL.
BillingInfoVerify:
type: object
properties:
Expand Down
28 changes: 28 additions & 0 deletions recurly/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -2979,6 +2979,34 @@ def list_external_subscription_external_invoices(
)
return Pager(self, path, **options)

def create_external_invoice(self, external_subscription_id, body, **options):
"""Create an external invoice

Parameters
----------

external_subscription_id : str
External subscription id
body : dict
The request body. It should follow the schema of ExternalInvoiceCreate.

Keyword Arguments
-----------------

headers : dict
Extra HTTP headers to send with the request.

Returns
-------

ExternalInvoice
Returns the external invoice
"""
path = self._interpolate_path(
"/external_subscriptions/%s/external_invoices", external_subscription_id
)
return self._make_request("POST", path, body, **options)

def list_invoices(self, **options):
"""List a site's invoices

Expand Down
Loading