Skip to content

Latest commit

 

History

History
62 lines (44 loc) · 1.84 KB

ReceiptApi.md

File metadata and controls

62 lines (44 loc) · 1.84 KB

BillaBear\ReceiptApi

All URIs are relative to https://{customerId}.billabear.cloud/api/v1

Method HTTP request Description
downloadReceipt GET /receipt/{receiptId}/download Download Receipt

downloadReceipt

string downloadReceipt($receipt)

Download Receipt

Returns the pdf blob for the Receipt

Example

<?php
require_once(__DIR__ . '/vendor/autoload.php');
// Configure API key authorization: ApiKeyAuth
$config = BillaBear\Configuration::getDefaultConfiguration()->setApiKey('X-API-Key', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// $config = BillaBear\Configuration::getDefaultConfiguration()->setApiKeyPrefix('X-API-Key', 'Bearer');

$apiInstance = new BillaBear\Api\ReceiptApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client(),
    $config
);
$receipt = "receipt_example"; // string | The id of the receipt

try {
    $result = $apiInstance->downloadReceipt($receipt);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling ReceiptApi->downloadReceipt: ', $e->getMessage(), PHP_EOL;
}
?>

Parameters

Name Type Description Notes
receipt string The id of the receipt

Return type

string

Authorization

ApiKeyAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/pdf

[Back to top] [Back to API list] [Back to Model list] [Back to README]