> For the complete documentation index, see [llms.txt](https://php-snap-bi.gitbook.io/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://php-snap-bi.gitbook.io/docs/the-basics/signature.md).

# Signature

Generate symmetric & asymmetric signature

{% hint style="warning" %}
Please set the [configuration](/docs/getting-started/configuration.md) first before using this Signature helper.
{% endhint %}

{% hint style="success" %}
All supported APIs automatically use signatures. You don't need to bother adding it manually
{% endhint %}

## Asymmetric

```php
use Otnansirk\SnapBI\Support\Signature;
use Otnansirk\SnapBI\Services\BCA\BcaConfig

$xSignature = Signature::asymmetric(BcaConfig::class)

```

## Symmetric

```php
use Otnansirk\SnapBI\Support\Signature;
use Otnansirk\SnapBI\Services\BCA\BcaConfig

$method       = "POST";
$path         = "/openapi/v1.0"; 
$body         = [];
$timestamp    = "time_iso_string" 
$accessToken  = "access_token"

$xSignature = Signature::symmetric(BcaConfig::class, $method, $path, $body, $timestamp, $accessToken)
```
