Skip to main content
GET
/
api
/
v1
/
projects
/
{id}
Get project
curl --request GET \
  --url https://api.dualship.run/api/v1/projects/{id} \
  --header 'Authorization: Bearer <token>' \
  --header 'X-Workspace-Id: <x-workspace-id>'
import requests

url = "https://api.dualship.run/api/v1/projects/{id}"

headers = {
"X-Workspace-Id": "<x-workspace-id>",
"Authorization": "Bearer <token>"
}

response = requests.get(url, headers=headers)

print(response.text)
const options = {
method: 'GET',
headers: {'X-Workspace-Id': '<x-workspace-id>', Authorization: 'Bearer <token>'}
};

fetch('https://api.dualship.run/api/v1/projects/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "https://api.dualship.run/api/v1/projects/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"X-Workspace-Id: <x-workspace-id>"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

import (
"fmt"
"net/http"
"io"
)

func main() {

url := "https://api.dualship.run/api/v1/projects/{id}"

req, _ := http.NewRequest("GET", url, nil)

req.Header.Add("X-Workspace-Id", "<x-workspace-id>")
req.Header.Add("Authorization", "Bearer <token>")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.get("https://api.dualship.run/api/v1/projects/{id}")
.header("X-Workspace-Id", "<x-workspace-id>")
.header("Authorization", "Bearer <token>")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.dualship.run/api/v1/projects/{id}")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["X-Workspace-Id"] = '<x-workspace-id>'
request["Authorization"] = 'Bearer <token>'

response = http.request(request)
puts response.read_body
{
  "created_at": "2024-01-15T10:30:00Z",
  "description": "API backend for mobile app",
  "id": "550e8400-e29b-41d4-a716-446655440000",
  "name": "My API Project",
  "organization_id": "550e8400-e29b-41d4-a716-446655440001",
  "slug": "my-api-project",
  "status": "active",
  "updated_at": "2024-01-15T10:30:00Z"
}
{
"code": "BAD_REQUEST",
"error": "invalid request parameters"
}
{
"code": "UNAUTHORIZED",
"error": "unauthorized"
}
{
"code": "NOT_FOUND",
"error": "resource not found"
}
{
"code": "INTERNAL_ERROR",
"error": "internal server error"
}

Authorizations

Authorization
string
header
required

JWT Bearer token authentication

Headers

X-Workspace-Id
string
required

Workspace ID

Path Parameters

id
string
required

Project ID

Response

Project details

Project information

created_at
string
Example:

"2024-01-15T10:30:00Z"

description
string
Example:

"API backend for mobile app"

id
string
Example:

"550e8400-e29b-41d4-a716-446655440000"

name
string
Example:

"My API Project"

organization_id
string
Example:

"550e8400-e29b-41d4-a716-446655440001"

slug
string
Example:

"my-api-project"

status
string
Example:

"active"

updated_at
string
Example:

"2024-01-15T10:30:00Z"