Welcome to the API reference for Nodana. You should have everything you need to deploy apps on Nodana using the API.
If you're looking for the Nodana CLI then you can find it here.
You will need to create a token to be able to use this API. This can be done on the Nodana website from the account section. Please be very careful with your tokens as they provide full read/write access to your projects and apps.
The API should be very easy to use but there are a few things to know:
- Only GET and POST methods are supported
- Uses method name in the route (/update, /delete etc)
- All responses (including errors) are 200 http status codes
See endpoint documentation below for a more detailed explanation.
https://api.nodana.io/<version>
You will need an api key to make requests. Please add this key to the password part of the Basic Authentication header. You should leave the username part of the header empty.
All calls should be made over https.
Keep your keys safe as they provide access to your projects and apps.
In general, requests are limited to 1 per second. Some endpoints may enforce stricter rates. Please do not repeatedly abuse the rate limits or keys will be banned.
If there is an internal error with the api (which shouldn't be very often) then there will be a 500 response so ensure you requests logic can catch unexpected errors.
All other responses are considered successful (200) so you need to examine the response payload to understand the outcome of the request:
Here's an example response:
{
"message": "Request is forbidden",
"error": "ForbiddenError",
"statusCode": 403
}Always check for the existence of error on the response object. If it exists then your request hasn't been successful. If there isn't an error property then your request has been successful and there will be a data property instead. Responses never include both data and error properties.
Projects allow you to group related apps and these apps can communicate with each other over a private network. Billing is applied to projects and you will be able to scope API keys to a project in the future.
Create a project.
POST /projects
curl -i -X POST \\
-H "Authorization: Basic :${API_KEY}" -H "Content-Type: application/json" \\
"${BASE_URL}/v1/projects" \\
-d '{
"name"="My Project",
}'{
"data": {
"id": "<project-id>",
"name": "My Project"
}
}Retrieve a project.
GET /projects/:id
curl -i -X GET \\
-H "Authorization: Basic :${API_KEY}" -H "Content-Type: application/json" \\
"${BASE_URL}/v1/projects/:id"{
"data": {
"id": "<project-id>",
"userId": "<user-id>",
"name": "New Project",
"deleted": false,
"createdAt": "2025-05-01T07:46:12.368Z",
"updatedAt": "2025-05-01T07:46:12.368Z"
}
}Update a project.
POST /projects/:id/update
curl -i -X POST \\
-H "Authorization: Basic :${API_KEY}" -H "Content-Type: application/json" \\
"${BASE_URL}/v1/projects/:id/update" \\
-d '{
"name"="My Updated Project",
}'{
"data": {
"id": "<project-id>",
"updated": true
}
}Delete a project. Note that only empty projects can be deleted.
POST /projects/:id/delete
curl -i -X POST \\
-H "Authorization: Basic :${API_KEY}" -H "Content-Type: application/json" \\
"${BASE_URL}/v1/projects/:id/delete"{
"data": {
"id": "<project-id>",
"deleted": true
}
}List all projects.
GET /projects
curl -i -X GET \\
-H "Authorization: Basic :${API_KEY}" -H "Content-Type: application/json" \\
"${BASE_URL}/v1/projects" \\{
"data": [
{
"id": "<project-id>",
"userId": "<user-id>",
"name": "New Project 1",
"deleted": false,
"createdAt": "2025-05-01T07:46:12.368Z",
"updatedAt": "2025-05-01T07:46:12.368Z"
},
{
"id": "<project-id>",
"userId": "<user-id>",
"name": "New Project 2",
"deleted": false,
"createdAt": "2025-05-01T07:46:12.368Z",
"updatedAt": "2025-05-01T07:46:12.368Z"
}
]
}List all apps within a project.
GET /projects/:id/apps
curl -i -X GET \\
-H "Authorization: Basic :${API_KEY}" -H "Content-Type: application/json" \\
"${BASE_URL}/v1/projects/:id/apps" \\{
"data": [
{
"id": "<app-id>",
"userId": "<user-id>",
"projectId": "<project-id>",
"template": "template-name",
"rate": 0.000233,
"url": "https://app-url.nodana.app:8000",
"status": "running",
"createdAt": "2025-05-24T08:07:10.509Z",
"updatedAt": "2025-05-24T08:07:10.509Z"
}
]
}Apps are the wrapper around the machine that run your chosen software.
Create an app. You can provide a project_id if you want the app to be assigned to an existing project. If you don't provide a project_id then a new project will be created automatically.
POST /apps
curl -i -X POST \\
-H "Authorization: Basic :${API_KEY}" -H "Content-Type: application/json" \\
"${BASE_URL}/v1/apps" \\
-d '{
"project_id"="prj-5fd3",
"template": "template-name",
"params": {
"prop-1": "value-1",
"prop-2": "value-2,
},
}'params is an object but the properties differ for each template. If the template isn't listed below then it doesn't accept config values.
You will receive a response to the Create App request immediately but it doesn't mean the app is running. It usually takes about 10 seconds for an app to start (but this can vary). You should use the Retrieve App endpoint to know when the status is "available".
| Property | Type | Possible Values |
|---|---|---|
auto_liquidity |
string | 2m, 5m, 10m |
| Property | Type | Possible Values |
|---|---|---|
mint_name |
string | |
mint_description |
string |
| Property | Type | Possible Values |
|---|---|---|
auto_liquidity |
string | 2m, 5m, 10m |
| Property | Type | Possible Values |
|---|---|---|
mint_name |
string | |
mint_description |
string | |
mint_lnd_rest_url |
string | |
mint_lnd_macaroon |
string |
| Property | Type | Possible Values |
|---|---|---|
auto_liquidity |
string | 2m, 5m, 10m |
webhook |
string |
{
"projectId": "<project-id>",
"id": "<app-id>",
"url": "https://app-url-1234.nodana.app:8080"
}The full response will differ depending on the template provided. For example, if you create a phoenixd node then the response will include a seed phrase, passwords etc.
Retrieve an app.
GET /apps/:id
curl -i -X GET \\
-H "Authorization: Basic :${API_KEY}" -H "Content-Type: application/json" \\
"${BASE_URL}/v1/apps/:id"{
"data": {
"id": "<app-id>",
"userId": "<user-id>",
"projectId": "<project-id>",
"template": "template-name",
"rate": 0.000233,
"url": "https://template-id-ad4f.nodana.app:8000",
"status": "available",
"createdAt": "2025-05-24T08:07:10.509Z",
"updatedAt": "2025-05-24T08:07:10.509Z"
}
}App status can either be "available", "cordoned" or "deleted".
Update an app to use the latest supported version.
POST /apps/:id/update
curl -i -X POST \\
-H "Authorization: Basic :${API_KEY}" -H "Content-Type: application/json" \\
"${BASE_URL}/v1/apps/:id/update"{
"data": {
"id": "<app-id>",
"image": "nodana/phoenixd:0.7.2",
"version": "0.7.2"
}
}Start an app.
POST /apps/:id/start
curl -i -X POST \\
-H "Authorization: Basic :${API_KEY}" -H "Content-Type: application/json" \\
"${BASE_URL}/v1/apps/:id/start"{
"data": {
"id": "<app-id>"
}
}Stop an app.
POST /apps/:id/stop
curl -i -X POST \\
-H "Authorization: Basic :${API_KEY}" -H "Content-Type: application/json" \\
"${BASE_URL}/v1/apps/:id/stop"{
"data": {
"id": "<app-id>"
}
}Restart an app.
POST /apps/:id/restart
curl -i -X POST \\
-H "Authorization: Basic :${API_KEY}" -H "Content-Type: application/json" \\
"${BASE_URL}/v1/apps/:id/restart"{
"data": {
"id": "<app-id>"
}
}Delete an app.
POST /apps/:id/delete
curl -i -X POST \\
-H "Authorization: Basic :${API_KEY}" -H "Content-Type: application/json" \\
"${BASE_URL}/v1/apps/:id/delete"{
"data": {
"id": "<app-id>"
}
}