curl
curl -sS -X PUT "https://gateway.orbit/api/v1/instances/12/database-connections/app" \
--cacert /path/to/orbit-root-ca.pem \
-H 'Accept: application/json' \
-H 'X-Orbit-Request-Id: 9d6b1e5c-4a3f-4a1b-9f0e-6d2c3f5a7b81' \
-H 'Content-Type: application/json' \
-d '{"prefix": "DB"}'{
"data": {
"instance_id": 123,
"slug": "<string>",
"prefix": "<string>",
"keys": [
"<string>"
],
"host": "<string>",
"port": 123,
"operation": "<string>",
"changed": true,
"key_count": 123
},
"meta": {
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": {},
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": {},
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": {},
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": {},
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
}Instances
Attach a Database connection
Add a Database connection on an Instance and write stored environment keys.
PUT
/
api
/
v1
/
instances
/
{instance}
/
database-connections
/
{database_connection}
curl
curl -sS -X PUT "https://gateway.orbit/api/v1/instances/12/database-connections/app" \
--cacert /path/to/orbit-root-ca.pem \
-H 'Accept: application/json' \
-H 'X-Orbit-Request-Id: 9d6b1e5c-4a3f-4a1b-9f0e-6d2c3f5a7b81' \
-H 'Content-Type: application/json' \
-d '{"prefix": "DB"}'{
"data": {
"instance_id": 123,
"slug": "<string>",
"prefix": "<string>",
"keys": [
"<string>"
],
"host": "<string>",
"port": 123,
"operation": "<string>",
"changed": true,
"key_count": 123
},
"meta": {
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": {},
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": {},
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": {},
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": {},
"request_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
}Path Parameters
Positive Instance ID or the exact Route domain of the Instance.
Database connection slug.
Pattern:
^[a-z0-9]+(?:-[a-z0-9]+)*$Body
application/json
Environment key prefix; defaults to DB
Pattern:
^[A-Z][A-Z0-9_]{0,31}$(?![\s\S])