# Get Invoice

## API Doc

Interactive API docs can be found at: <https://run.truebit.network/transcript-query/api-docs/>

## Overview

By calling this endpoint, you’ll receive the Invoice Transcript associated with the given  `executionId`  or `transcriptHash`.

## Find transcript invoice by executionId

> Returns the transcript invoice associated with the given executionId parameter

```json
{"openapi":"3.1.0","info":{"title":"Transcript and Invoice","version":"1.120.0-beta.311"},"tags":[{"name":"Invoice","description":"Invoice info of a task execution"}],"servers":[{"description":"Public beta","url":"https://run.truebit.network"},{"description":"Current environment relative paths","url":"/"}],"paths":{"/task/{executionId}/transcriptInvoice":{"get":{"operationId":"getTranscriptInvoiceByExecutionId","tags":["Invoice"],"summary":"Find transcript invoice by executionId","description":"Returns the transcript invoice associated with the given executionId parameter","parameters":[{"name":"executionId","in":"path","description":"Execution Id","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Successful operation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Invoice"}}}},"404":{"description":"Cannot find any invoice for given executionId","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"}}}}}}}}}},"components":{"schemas":{"Invoice":{"type":"object","properties":{"executionId":{"type":"string"},"taskId":{"type":"string"},"taskCreated_timeStamp":{"type":"integer"},"invoiceId":{"type":"string"},"stepGasPrice":{"type":"number"},"byteGasPrice":{"type":"number"},"accounting_signature":{"type":"string"},"lineItem":{"type":"array","items":{"$ref":"#/components/schemas/LineItem"}}}},"LineItem":{"type":"object","properties":{"operation":{"type":"string","enum":["Pay","Charge","Penalty"]},"account":{"type":"string"},"total_steps_computed":{"type":"integer"},"peak_memory_used":{"type":"integer"},"totalTransferredBytes":{"type":"object","properties":{"request":{"type":"integer"},"response":{"type":"integer"}}},"reason":{"type":"string"}}}}}}
```

### Response Data

It returns the Invoice Transcript associated with the given `executionId`  or `transcriptHash`  &#x20;

* [Invoice Transcript example](/architecture/execution-transcripts/invoice-transcript.md)


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://devs.truebit.io/integrating-truebit-tasks/get-invoice.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
