Build a portfolio
curl --request GET \
--url https://api.atlasyield.club/v1/portfolioimport requests
url = "https://api.atlasyield.club/v1/portfolio"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.atlasyield.club/v1/portfolio', 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.atlasyield.club/v1/portfolio",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$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.atlasyield.club/v1/portfolio"
req, _ := http.NewRequest("GET", url, nil)
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.atlasyield.club/v1/portfolio")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.atlasyield.club/v1/portfolio")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"success": true,
"riskTier": "balanced",
"timeline": "medium",
"principal": 10000,
"strategy": "MVO",
"fallback": false,
"allocations": [
{
"vaultId": "morpho:1:0xbeefc1cdafc5b4a649b54d07afc6bf0f75c6f4e2",
"protocol": "morpho",
"protocolId": "morpho",
"chainId": 1,
"asset": "USDC",
"name": "STEAKUSDTBETHENA",
"apy": 12.18706,
"tvl": 11780173,
"composite": 78.762,
"fraction": 0.15,
"allocationPct": 15,
"allocationUsd": 1500,
"vaultAddress": "0xbeefc1cdafc5b4a649b54d07afc6bf0f75c6f4e2",
"underlyingToken": "0xc139190f447e929f090edeb554d95abb8b18ac1c"
}
],
"expectedApy": 4.69,
"expectedSharpe": 14.58,
"unallocatedUsd": 0,
"vaultCountCap": 5,
"capRelaxed": [
"chain"
],
"shortHistoryShare": 0,
"scorerVersion": "2.4.0",
"generatedAt": "2023-11-07T05:31:56Z",
"disclaimer": "Research and information, not investment advice.",
"note": "<string>"
}{
"success": false,
"error": "Invalid params: address must be a 0x-prefixed 40-character hex address",
"details": [
{
"field": "address",
"message": "must be a 0x-prefixed 40-character hex address"
}
]
}{
"success": false,
"error": "Scoring data is stale — portfolio unavailable"
}Endpoints
Build a portfolio
The Atlas Engine as a service. Give it a risk tier, a timeline, and a principal; it runs the mean-variance allocator over the current scored universe and returns the resulting allocation, sized in dollars.
Unlike /scores and /catalog, this endpoint fails closed on stale scoring: an allocation is an active recommendation, so if the most recent scoring run is too old the endpoint returns 503 rather than allocating on stale data.
The allocator is deterministic — the same inputs against the same scoring snapshot return the same portfolio.
GET
/
portfolio
Build a portfolio
curl --request GET \
--url https://api.atlasyield.club/v1/portfolioimport requests
url = "https://api.atlasyield.club/v1/portfolio"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.atlasyield.club/v1/portfolio', 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.atlasyield.club/v1/portfolio",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$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.atlasyield.club/v1/portfolio"
req, _ := http.NewRequest("GET", url, nil)
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.atlasyield.club/v1/portfolio")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.atlasyield.club/v1/portfolio")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"success": true,
"riskTier": "balanced",
"timeline": "medium",
"principal": 10000,
"strategy": "MVO",
"fallback": false,
"allocations": [
{
"vaultId": "morpho:1:0xbeefc1cdafc5b4a649b54d07afc6bf0f75c6f4e2",
"protocol": "morpho",
"protocolId": "morpho",
"chainId": 1,
"asset": "USDC",
"name": "STEAKUSDTBETHENA",
"apy": 12.18706,
"tvl": 11780173,
"composite": 78.762,
"fraction": 0.15,
"allocationPct": 15,
"allocationUsd": 1500,
"vaultAddress": "0xbeefc1cdafc5b4a649b54d07afc6bf0f75c6f4e2",
"underlyingToken": "0xc139190f447e929f090edeb554d95abb8b18ac1c"
}
],
"expectedApy": 4.69,
"expectedSharpe": 14.58,
"unallocatedUsd": 0,
"vaultCountCap": 5,
"capRelaxed": [
"chain"
],
"shortHistoryShare": 0,
"scorerVersion": "2.4.0",
"generatedAt": "2023-11-07T05:31:56Z",
"disclaimer": "Research and information, not investment advice.",
"note": "<string>"
}{
"success": false,
"error": "Invalid params: address must be a 0x-prefixed 40-character hex address",
"details": [
{
"field": "address",
"message": "must be a 0x-prefixed 40-character hex address"
}
]
}{
"success": false,
"error": "Scoring data is stale — portfolio unavailable"
}Headers
Query Parameters
Response
The proposed allocation.