---
title: Receipts
editUrl: false
head: []
template: doc
prev: false
next: false
sidebar:
  hidden: false
  attrs: {}
pagefind: true
draft: false
---

Defined in: [src/expenses/client.gen.ts:115](https://github.com/slingshot/brex/blob/9dff46b5d5637a0dd072bca56d02d8a0f4425312/src/expenses/client.gen.ts#L115)

## Constructors

### Constructor

> **new Receipts**(`_core`): `Receipts`

Defined in: [src/expenses/client.gen.ts:116](https://github.com/slingshot/brex/blob/9dff46b5d5637a0dd072bca56d02d8a0f4425312/src/expenses/client.gen.ts#L116)

#### Parameters

##### \_core

[`BrexCore`](/brex/api/index/classes/brexcore/)

#### Returns

`Receipts`

## Methods

### match()

> **match**(`body`, `options?`): `Promise`\<\{ `id`: `string`; `uri`: `string`; \}\>

Defined in: [src/expenses/client.gen.ts:127](https://github.com/slingshot/brex/blob/9dff46b5d5637a0dd072bca56d02d8a0f4425312/src/expenses/client.gen.ts#L127)

Create a new receipt match

The `uri` will be a pre-signed S3 URL allowing you to upload the receipt securely. This URL can only be used for a `PUT` operation and expires 30 minutes after its creation. Once your upload is complete, we will try to match the receipt with existing expenses.

Refer to these [docs](https://docs.aws.amazon.com/AmazonS3/latest/dev/PresignedUrlUploadObject.html) on how to upload to this pre-signed S3 URL. We highly recommend using one of AWS SDKs if they're available for your language to upload these files.

`POST /v1/expenses/card/receipt_match`

#### Parameters

##### body

###### receipt_name

`string`

**Description**

The name of the receipt (with the file extension). It will be used in the matching result email.

##### options?

[`RequestOptions`](/brex/api/index/interfaces/requestoptions/)

#### Returns

`Promise`\<\{ `id`: `string`; `uri`: `string`; \}\>

***

### upload()

> **upload**(`expenseId`, `body`, `options?`): `Promise`\<\{ `id`: `string`; `uri`: `string`; \}\>

Defined in: [src/expenses/client.gen.ts:149](https://github.com/slingshot/brex/blob/9dff46b5d5637a0dd072bca56d02d8a0f4425312/src/expenses/client.gen.ts#L149)

Create a new receipt upload

The `uri` will be a pre-signed S3 URL allowing you to upload the receipt securely. This URL can only be used for a `PUT` operation and expires 30 minutes after its creation. Once your upload is complete, we will try to match the receipt with existing expenses.

Refer to these [docs](https://docs.aws.amazon.com/AmazonS3/latest/dev/PresignedUrlUploadObject.html) on how to upload to this pre-signed S3 URL. We highly recommend using one of AWS SDKs if they're available for your language to upload these files.

`POST /v1/expenses/card/{expense_id}/receipt_upload`

#### Parameters

##### expenseId

`string`

##### body

###### receipt_name

`string`

**Description**

The name of the receipt (with the file extension).

##### options?

[`RequestOptions`](/brex/api/index/interfaces/requestoptions/)

#### Returns

`Promise`\<\{ `id`: `string`; `uri`: `string`; \}\>