# Digital entity

There are 3 types of entities that we use in the processing center:

1. identification entity - for creating digital identificators
2. processing entity - for distribution of identificators between branches and customers
3. customer's entity - each external user has their own Stellar entity

{% hint style="info" %}
**Note**: a digital entity has one identificator assigned.&#x20;

Entity has status attributes:

* activated
* registered
* blocked

The attributes are not used currently.
{% endhint %}

## Create an additional processing entity

Entities are created in 4 ways:

1. a counterparty is already created with 2 digital entities: an identification and a processing.&#x20;
2. an employee can create an additional processing entity for their Counterparty (e.g., to separate identificator flow between branches) - see below.
3. an employee can create an digital entity for a customer (each customer has their own Stellar entity) - see [#create-additional-customer-account](https://docs.prozora.network/bank-integration/eng/customer#create-additional-customer-account "mention").
4. a customer can create an entity for themselves (not yet implemented).

{% openapi src="<https://3204608041-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FtSAbV2p2auxzoLyMptKl%2Fuploads%2FKuhgCdlBgK52E1wevSff%2Fmaster.yaml?alt=media&token=83700834-337f-45f5-944e-894dbc762bf3>" path="/counterparty/{counterparty\_guid}/accounts" method="post" %}
[master.yaml](https://3204608041-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FtSAbV2p2auxzoLyMptKl%2Fuploads%2FKuhgCdlBgK52E1wevSff%2Fmaster.yaml?alt=media\&token=83700834-337f-45f5-944e-894dbc762bf3)
{% endopenapi %}

The attribute `branch_guid` is optional.&#x20;

## Get entity list

Get the list of accounts that are visible to the user.

{% openapi src="<https://3204608041-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FtSAbV2p2auxzoLyMptKl%2Fuploads%2FKuhgCdlBgK52E1wevSff%2Fmaster.yaml?alt=media&token=83700834-337f-45f5-944e-894dbc762bf3>" path="/counterparty/{counterparty\_guid}/accounts" method="get" %}
[master.yaml](https://3204608041-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FtSAbV2p2auxzoLyMptKl%2Fuploads%2FKuhgCdlBgK52E1wevSff%2Fmaster.yaml?alt=media\&token=83700834-337f-45f5-944e-894dbc762bf3)
{% endopenapi %}

The filter `search_string` accepts the following values:

1. `customer_guid` - the unique identifier of the customer. More you can find [here](https://docs.prozora.network/bank-integration/eng/api-methods/customer)
2. `account_guid` - the unique identifier of the digital entity
3. `account_iban` - IBAN of an account without spaces
4. `customer.login` - customer's login, which was assigned upon customer registration
5. `customer.external_id` - customer's external identifier, can be the same as `login`&#x20;

## Get digital entity

Get the accounts for the counterparty.

{% openapi src="<https://3204608041-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FtSAbV2p2auxzoLyMptKl%2Fuploads%2FKuhgCdlBgK52E1wevSff%2Fmaster.yaml?alt=media&token=83700834-337f-45f5-944e-894dbc762bf3>" path="/counterparty/{counterparty\_guid}/accounts/{account\_guid}" method="get" %}
[master.yaml](https://3204608041-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FtSAbV2p2auxzoLyMptKl%2Fuploads%2FKuhgCdlBgK52E1wevSff%2Fmaster.yaml?alt=media\&token=83700834-337f-45f5-944e-894dbc762bf3)
{% endopenapi %}

{% hint style="info" %}
Admin user can get all available digital entities.

Bank employee can get all digital entities except the distributor entity.
{% endhint %}
