# SIGNATURE

## Route: /sign

### Description

This endpoint generates a unique signature for a specified wallet address and saves it using Redis. It also supports an optional header signature and secure signing via UUID.

### Method

`GET`

### Query Parameters

* `wallet` (required): The wallet address to generate the signature for.
* `contract_id` (optional): The contract ID &#x20;
* `header_signature` (optional): An optional header signature to prepend to the generated signature.
* `secure_sign` (optional): If provided, a secure UUID-based sign ID will be used to save the signature.

### Responses

#### Success

* **Status**: 200 OK
* **Content-Type**: application/json
* **Body**:

  ```json
  {
    "status": true,
    "message": "get_sign",
    "data": {
      "signature": "generated-signature",
      "sign_id": "uuid-sign-id" // Only if secure_sign is provided
    }
  }
  ```

## Route: /check

### Description

This endpoint checks the validity of a signature for a specified wallet address to ensure permission.

### Method

`GET`

### Query Parameters

* `sign_message` (required): The signed message to be validated.
* `sign_id` (optional): The identifier of the signature.
* `wallet` (required): The wallet address to match against the signature.

### Responses

#### Success

* **Status**: 200 OK
* **Content-Type**: application/json
* **Body**:

  ```json
  {
    "status": true,
    "message": "good signature",
    "connexion": true
  }
  ```


---

# 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://docs.certhis.io/api-endpoints/signature.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.
