> For the complete documentation index, see [llms.txt](https://university.gonexa.fr/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://university.gonexa.fr/rf/en/getting-started/configure-rf/configure-legal-entity.md).

# Set up the legal entity

Still from the Legal Entity object you just created, click the New button next to Legal Entity Configuration to set up the mapping of your tax receipt.

## Tax receipt mapping

* Still from the Legal Entity object you just created, click the New button next to Legal Entity Configuration to set up the mapping of your tax receipt.
* Name your configuration
* Choose the legal entity to associate with this configuration
* Select the document template you set up previously from the drop-down list.
* Choose the default configuration to apply and, from it, check the "Default configuration" box

{% hint style="info" %}
Note that a default configuration is unique and mandatory.
{% endhint %}

## Default mapping

Gonexa RF offers a default mapping based on the fields of the Salesforce NPSP package.

* Keep the default mapping or customize it to fit your object model.
* Check the configuration of the receipt and its lines, and click Save

{% hint style="info" %}
The default configuration provided is based on the Opportunity object and retrieves the tax receipt and payment fields: the tax receipt lines.
{% endhint %}

## Creating your own mapping

If your data model requires it, you can customize your own mapping by choosing the fields to fill in on your tax receipt.

* Once the default configuration is validated, customize the header mapping by clicking the Edit icon in the first step.
* Choose the Salesforce object from which you want to create the tax receipt; its fields are the ones you will use for the tax receipt mapping.\
  E.g. Contact, Opportunity, Don\_\_c...
* Search for the fields available on your object to define the elements of the tax receipt: information about the corporate or individual donor, and the donor's address.

{% hint style="info" %}
Leave fields empty if they are not used, and go up your object relationships to retrieve information from lookups.
{% endhint %}

* Save this first step.
* Go to the second step by clicking the edit icon next to the tax receipt mapping.
* Choose the Salesforce object from which you want to create the tax receipt child objects.\
  E.g. Payment
* Search for the fields available on your object to define the amount elements of the tax receipt lines
* Add filters if you don't want to display all the items of your donation. Build the filter by writing a SOQL condition.\
  E.g. `statut__c = 'réglé'`
* Click Save.

{% hint style="warning" %}
Make sure you select fields of the expected type. If an amount is expected, only a number field should be chosen; a date expects a date field, and so on.
{% endhint %}


---

# 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://university.gonexa.fr/rf/en/getting-started/configure-rf/configure-legal-entity.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.
