# Submit new block

## Creates a new block

<mark style="color:orange;">`PUT`</mark> `https://test-001-node.cloud.nxtfi.tech/v2/newBlock`

#### Request Body

| Name                                        | Type   | Description                                                                                                                                           |
| ------------------------------------------- | ------ | ----------------------------------------------------------------------------------------------------------------------------------------------------- |
| prevhash<mark style="color:red;">\*</mark>  | String | Last recorded hash of the scope                                                                                                                       |
| height<mark style="color:red;">\*</mark>    | Number | Heght of the last block of the scope + 1                                                                                                              |
| version<mark style="color:red;">\*</mark>   | Number | API version                                                                                                                                           |
| data<mark style="color:red;">\*</mark>      | String | Block Content                                                                                                                                         |
| timestamp<mark style="color:red;">\*</mark> | Number | Timestamp in [Unix](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date#the_ecmascript_epoch_and_timestamps) format |
| by<mark style="color:red;">\*</mark>        | String | Transaction Signer name                                                                                                                               |
| scope<mark style="color:red;">\*</mark>     | String | Scope name                                                                                                                                            |
| signature<mark style="color:red;">\*</mark> | String | <p>RSA-PSS signature of the object</p><p><code>{ prevHash, height, version, data, timestamp, scope }</code></p>                                       |
| hash<mark style="color:red;">\*</mark>      | String | Cryptographic hash (digest) encrypted with [SHA-256](https://en.wikipedia.org/wiki/SHA-2)                                                             |

{% tabs %}
{% tab title="200: OK Block successfully created" %}

{% endtab %}
{% endtabs %}

### Example in curl

{% tabs %}
{% tab title="Curl" %}

```bash
curl --location --request PUT 'https://test-001-node.cloud.nxtfi.tech/v2/newBlock' \
--header 'Content-Type: application/json' \
--data-raw '{
    "prevHash": "bd125e337f0cc7782b0e3465157b60535151362220f490650bed6b4be69bbb4b",
    "height": 14,
    "version": 2,
    "data": "Hello World!",
    "timestamp": 1676462543625,
    "scope": "DATA",
    "signature": "Vicd0mJ1mtXHleomOYsZ1oIZCeu+5P6EZLP/yRAABbvueTdMmJ1YbfnrbQ44ZJtAVwTI0NljyDoU62QvgnTEyCaJWwGR9URW+cAf15tupbkefJWrawmTOWuu3p4kBbOlF2Vk2oClnsUOpUrnzQ7AfdTa30bH87xpHLPUlvmxMw3Q3iCBH8908chKO/t/b7bI/8PGVDejYx13g2UCvJB0dcFHS8XAhAE0NwKpN33KVLCGAc5EoxLKF2mTCw5EejGxh19DbK05RbRZ8GL2j5MikyFlYVZexRIs6T3Rwr5zBacm1xw+P52WHRaDDHyAkVKd3XCvN6P18HRJWd5he+IOiw==",
    "by": "DATA",
    "hash": "d1966d2adabdcd65eb904dec2abc1179f02e2e6a5b3428e4ddf05d3a9a7a0276"
}'
```

{% endtab %}
{% endtabs %}

### Response

```javascript
{
    "verified": true,
    "queued": true
}
```
