# Klaytn

## Sign Transaction

The D'CENT Web SDK provides functions for signing transaction of coins.

### **getKlaytnSignedTransaction()**

For broadcast the sign value, you must encoding the parameter values using RLP. Klaytn provides 'caver-js' library. You can make raw transaction for broadcasting using 'caver-js'. (<https://docs.klaytn.com/bapp/sdk/caver-js/api-references>)

#### Supported Coin Type

* KLAYTN
* KLAYTN\_KCT

#### Parameters&#x20;

* coinType
* nonce
* gasPrice
* gasLimit
* to (address)
* value
* data
* key path for signing
* chain ID
* Transaction type
* from (address)
* fee ratio
* contract information example :

  ```javascript
  {
    name: 'COSM',
    decimals: 18,
    symbol: 'COSM'
  }  
  ```

#### Returned response object:

```json
{
    "header": {
        "version": "1.0",
        "response_from": "klaytn",
        "status": "success"
    },
    "body": {
        "command": "transaction",
        "parameter": {
            "sign_v": "0x4055",
            "sign_r": "0x5b1a8134......697ce449",
            "sign_s": "0x6aea20f1......9eb816fb"
        }
    }
}
```
