> ## Documentation Index
> Fetch the complete documentation index at: https://docs-en.keysecure.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Getting Started

## Overview

Welcome to the Keysecure platform. This document is used by the third-party technical team to add the self-developed mainchain to the Keysecure for alliance members.

> [!NOTE]
>
> **Note**
>
> When third-party technical team using WAPI to access the the server and keeping private keys, Keysecure is not responsible for the security of assets. Therefore, the third-party technical team must establish a complete private key Keysecure System and API private key Keysecure System

## Development Notes

The Role of Public and Private Keys

* **Party A** is a third-party public chain docking party

* **Party B** is the Keysecure BaaS Cloud

* **The Role of Public and Private Keys**： Party A needs to generate a pair of public and private keys in advance when registering the WAPI interface. The public key (rsa\_third\_pub) is provided to Party B. The private key is kept by yourself, and the private key is not disclosed to anyone. When requesting WAPI services, Party A shall encrypt the request parameters with Party B’s public key and sign the original data after MD5 with Party A’s private key. Upon receiving the request, Party B shall decrypt the data with Party B’s private key and check the original data after MD5 with Party A’s public key

## Account Preparation

* Developers need to prepare the following information：

1. Generate a pair of public and private keys, and provide the public key to the platform；

2. Third-party application server IP；

* Contact the relevant people of the platform and provide the above two types of information. The platform prepares WAPI docking information for you, and provides you with the following information：

1. The unique identifier for third-party docking: app\_id；

2. WAPI public key：rsa\_wapi\_pub

* RSA public and private key:

Password length：`2048`

Key format：`PKCS#8`

```sh theme={null}
openssl genrsa -out rsa_private_key.pem 2048

openssl rsa -in rsa_private_key.pem -pubout -out rsa_public_key_2048.pem

openssl pkcs8 -topk8 -inform PEM -in rsa_private_key.pem -outform pem -nocrypt -out private_pkcs8.pem
```

## Interface rules

| Transmission method: | https (the test environment temporarily uses http) |
| :- | - |
| Signature Field: | Except for the `sign`  field, all other required fields need to be signed |
| The response status code: | `0`indicating successful processing; **non-zero**, indicating request error or system abnormality |
| Request Address: | domain name + interface address |
| Encryption Algorithm: | Java Encryption and [Decryption Demo](https://github.com/HiCoinCom/WAPIDemo.git) |

## Domain Name and API Key

### Production Environment

| Domain Name: | [https://baas.waas.group](https://baas.waas.group/) |
| :- | - |
| app\_id: | To be assigned |
| rsa\_wallet\_pub: | To be allocated |

### Test environment

| Domain Name: | [http://baas.dw2nn.com](http://baas.dw2nn.com) |
| :- | - |
| **app\_id:** | 8ee3794a7e5bd188c6af4fd7dda191f3 |

> rsa\_third\_pub:

```text theme={null}
MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEA0P18OcSRr2mnWAWwn6hWlKCyChBb8bF6X1gHiFfdyejHmPnni60j6uKEHhAB7L9xyCnvpP44Wzp7txjNfYF+8SiaFUVP5rawisiHrcUHxvKEInVdyjeE6dUnDvr7acFTmF0JZCbfzDA38l5WznDV3AWESOm7Gd/0NP7rCiZDbn+2uOlrGqsYSi4cLwCnoqREQ+/Z7rNug8l3Vlqvvx6YVj0xxWi/4qz8yXlZV8aBAN1rshAkaTVbkWjij6uSJ3lMHY99B5DqnF/5EAhYYc+GTgAML5KAHfHYlF+Y9GDlKZoBaixIK/X3HtgBOaIIDaCZFLSQaO36ghIEpyjnepgXBQIDAQAB
```

> rsa\_third\_prv:

```text theme={null}
MIIEvwIBADANBgkqhkiG9w0BAQEFAASCBKkwggSlAgEAAoIBAQDQ/Xw5xJGvaadYBbCfqFaUoLIKEFvxsXpfWAeIV93J6MeY+eeLrSPq4oQeEAHsv3HIKe+k/jhbOnu3GM19gX7xKJoVRU/mtrCKyIetxQfG8oQidV3KN4Tp1ScO+vtpwVOYXQlkJt/MMDfyXlbOcNXcBYRI6bsZ3/Q0/usKJkNuf7a46WsaqxhKLhwvAKeipERD79nus26DyXdWWq+/HphWPTHFaL/irPzJeVlXxoEA3WuyECRpNVuRaOKPq5IneUwdj30HkOqcX/kQCFhhz4ZOAAwvkoAd8diUX5j0YOUpmgFqLEgr9fce2AE5oggNoJkUtJBo7fqCEgSnKOd6mBcFAgMBAAECggEAcpe7aPWGqHc3QgWErlagesiONwR3VdRp9CORpcoAG7ke0JuewbDDNATWSqGeXJEws3+DHqYigqtTsLbR3hKGZ3dK3YTu5eOgc8i21K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dbmGcz/mQ1+Msf0RT+/KGvjX+GenjpYiTQc7n2CwYypnN9ru8KA
```

> rsa\_baas\_pub:

```
MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAmY3x4DVuU2NV90HaXZWnxGj7XvuBtwGT4bvnCiDcpMVlNuQN1cr+Vg+WMPIUihWmWkupA9oXdZf4LzWtqv2SRlP3tIs+tWG4Df3FuuZ0W2CIxhtJNnWHIY146m/teif+H2v9G3GeY+P+z/LqGFyV0nLYJzs4WQZa3/RL0rh2IlVlfs1eHod+PX99o+Aog80kmUx8NF6ExsoO4qI9y3wW8CH+5tGVqHvq3NaD3jHyS3DYrRztfxuJw9k/YTfZ6rDJVXmD7onqvZe2leSe5h/ehu321y7nB7+2uTJ76i1YOmIrEBW8KupwQUU1JuZKvMCzcLowLjIOYysU8JfpxXH+MQIDAQAB
```

| Type | Token Name | Accuracy |
| - | - | - |
| memo | SRM | 8 decimals |
| non-memo | VLX | 8 decimals |

> [!NOTE]
>
> **Note**
>
> `rsa_third_prv` is a third-party application private key, which is mainly used to encrypt request parameters. If it is a production environment, `rsa_third_prv` is generated by the developer, and then the corresponding public key is provided to the platform. In order to simplify the developer connection process in the test environment, a set of third-party public and private keys and token names are directly provided here for developers to quickly connect.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.