> For the complete documentation index, see [llms.txt](https://docs.aeternity.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.aeternity.com/developer-documentation/aepp-sdk-js/docs/guides/paying-for-tx.md).

# PayingForTx (Meta-Transactions)

## Introduction

This guide explains you how to perform a `PayingForTx` (also known as meta-transaction) using the SDK.

It is a very powerful and efficient solution that is crucial for onboarding new users into you ecosystem. By making use of the `PayingForTx` you will be able to cover the fees of your users.

## How it works

Typically somebody that you want to pay the transaction for (e.g. a new user of your decentralized aepp) signs the **inner transaction** (e.g. of type `ContractCallTx`) with a **specific signature** that is used for inner transactions.

You can then collect the signed inner transaction, wrap it into a `PayingForTx` and broadcast it to the network.

## Usage examples

We provided following two NodeJS examples which you can take a look at:

* [InnerTx: ContractCallTx](https://sdk.aeternity.io/v14.1.0/examples/node/paying-for-contract-call-tx/)
* [InnerTx: SpendTx](https://sdk.aeternity.io/v14.1.0/examples/node/paying-for-spend-tx/)

Note:

* A `PayingForTx` can wrap **any kind** of other [transaction type](https://docs.aeternity.com/developer-documentation/protocol/consensus#transactions-1) supported by the protocol as inner transaction.

## UseCases

* Game developers that want to quickly onboard new users.
* Governance aepps that want people to vote on important proposals without having them to pay anything.
* Custodians that want to offer an additional services to cover the transaction fees of their clients.
* ... many more!


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

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

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.aeternity.com/developer-documentation/aepp-sdk-js/docs/guides/paying-for-tx.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
