ALM (v3)
This API is already deprecated.

Endpoint

1
https://api.mobingi.com
Copied!

OAuth Authentication

In order to interact with the API, your application must authenticate. Mobingi API handles this through OAuth. An OAuth token functions as a complete authentication request. In effect, it acts as a substitute for a username and password pair.
To get an OAuth token, make a POST request to
POST /v3/access_token
Parameters
Type
Required
Detail
client_id
string
Yes
client_secret
string
Yes
grant_type
string
Yes
This value is either client_credentials or password. If you grant with password, you are interacting the same as working around Mobingi UI; If you grant with client_credentials, you are acting as an Alm-Agent, and most resource related permissions are denied by RBAC.
Example Request:
1
curl -X POST https://api.mobingi.com/v3/access_token \
2
-H "Content-Type: application/json" \
3
-d '{"grant_type":"client_credentials","client_id":"lg-5447820c870e1-xBV0OpTEN-tm","client_secret":"sFVYDoe07fxPjNgYvauYGOYCeXbOTE"}'
Copied!
Response Body:
1
{
2
"token_type": "Bearer",
3
"expires_in": 43200,
4
"access_token": "eyJ0eXAiOiJQiLCJhbGciOMeXzQfME"
5
}
Copied!
You can then start making API requests by passing the access_token value to the Authorization Header
1
Authorization: Bearer eyJ0eXAiOiJQiLCJhbGciOMeXzQfME
Copied!

ALM Templates

Apply Template

Applies the Mobingi Alm template and creates stack.
POST /v3/alm/template
Parameters
Type
Required
Detail
{ template body }
string
Yes
Mobingi Alm template body in json string format
Request Header
1
Authorization: Bearer eyJ0eXAiOiJQiL...CJhbGciOMeXzQfME
2
Content-Type: application/json
Copied!
Request body
1
{
2
"version": "2017-03-03",
3
"label": "template version label #1",
4
"description": "This template creates a sample stack with EC2 instance on AWS",
5
"vendor": {
6
"aws": {
7
"cred": "AKIAJ...DZLA",
8
"region": "ap-northeast-1"
9
}
10
},
11
"configurations": [
12
{
13
"role": "web",
14
"flag": "Web01",
15
"provision": {
16
"image": "${computed}",
17
"volume_type": "${computed}",
18
"instance_type": "t2.micro",
19
"instance_count": 1,
20
"keypair": true
21
}
22
}
23
]
24
}
Copied!
Response Body
1
HTTP/1.1 201 Created
2
3
{
4
"status": "success",
5
"stack_status": "CREATE_IN_PROGRESS",
6
"stack_id": "mo-5447820c870e1-ZgNTSRM8K-tk",
7
"version_id": "98O0jK6CQk8qLi14S2SLU8z3JIo3.JPx"
8
}
Copied!

Update Template

Updates the Mobingi Alm template and applies the changes to stack resources.
Note: vendor section will be ignored when performing this API call. You can not change cloud vendors after the stack is created.
PUT /v3/alm/template/{stack_id}
Parameters
Type
Required
Detail
{ template body }
string
Yes
Mobingi Alm template body in json string format
Request Header
1
Authorization: Bearer eyJ0eXAiOiJQiL...CJhbGciOMeXzQfME
2
Content-Type: application/json
Copied!
Request body
1
{
2
"version": "2017-03-03",
3
"label": "template version label #2",
4
"description": "This template creates a sample stack with EC2 instance on AWS",
5
"vendor": {
6
"aws": {
7
"cred": "AKIAJ...DZLA",
8
"region": "ap-northeast-1"
9
}
10
},
11
"configurations": [
12
{
13
"role": "web",
14
"flag": "Web01",
15
"provision": {
16
"image": "${computed}",
17
"instance_type": "m3.medium",
18
"instance_count": 2,
19
"keypair": true
20
}
21
}
22
]
23
}
Copied!
Response Body
1
HTTP/1.1 202 Accepted
2
3
{
4
"status": "success",
5
"stack_status": "UPDATE_IN_PROGRESS",
6
"stack_id": "mo-5447820c870e1-ZgNTSRM8K-tk",
7
"version_id": "gCn2JuPhndwxMZuidOER0yyxM8jZB6Vn"
8
}
Copied!

Compare Templates

Compares the resource changes between two Mobingi Alm templates.
POST /v3/alm/template/compare
Parameters
Type
Required
Detail
id
array
conditional
items contain stack id and version information
body
array
conditional
items contain template body source
Note: You can compare two templates by retrieving them from their version id and stack id. Or, you can compare a target template body (posted in json format to body parameter) with a source template retrieved by its version id and stack id.
The current API version only supports two templates comparison, and you always should retrieve the source template by its version id and stack id. That being said, you have to always pass at least one item in parameter id array. Below are two examples:
Request Header
1
Authorization: Bearer eyJ0eXAiOiJQiL...CJhbGciOMeXzQfME
2
Content-Type: application/json
Copied!
Request body ( Example 1 )
1
{
2
"id": [
3
{
4
"mo-5447826c870e7-ZgNTSRM8K-tk": {
5
"version": "98O0jK5CQk8gLi14S2SLU8z3JIo3.JPx"
6
}
7
},
8
{
9
"mo-5447826c870e7-ZgNTSRM8K-tk": {
10
"version": "gCn2JuPhndwxMZuodOER0yyxM8jZB6Vn"
11
}
12
}
13
]
14
}
Copied!
Request body ( Example 2 )
1
{
2
"id": [
3
{
4
"mo-5447826c870e7-9S3zWP7jM-tk": {
5
"version": "dK7R9_PuclTqSysMniPTcmpE.5u58RVL"
6
}
7
}
8
],
9
"body": [
10
"{\n \"version\": \"2017-03-03\",\n \"label\": \"template version label #2\",\n \"description\": \"This template creates a sample stack with EC2 instance on AWS\",\n \"vendor\": {\n \"aws\": {\n \"cred\": \"AKIAJ...DZLA\",\n \"region\": \"ap-northeast-1\"\n }\n },\n \"configurations\": [\n {\n \"role\": \"web\",\n \"flag\": \"Web01\",\n \"provision\": {\n \"image\": \"${computed}\", \"instance_type\": \"m3.medium\",\n \"instance_count\": 2,\n \"keypair\": true,\n }\n }\n ]\n }"
11
]
12
}
Copied!
Response Body
1
HTTP/1.1 202 Accepted
2
3
{
4
"status": "success",
5
"source":{
6
"version": "2017-03-03",
7
"label": "template version label #1",
8
"description": "This template creates a sample stack with EC2 instance on AWS",
9
"vendor": {
10
"aws": {
11
"cred": "AKIAJ...DZLA",
12
"region": "ap-northeast-1"
13
}
14
},
15
"configurations": [
16
{
17
"role": "web",
18
"flag": "Web01",
19
"provision": {
20
"image": "${computed}",
21
"instance_type": "t2.micro",
22
"volume_type": "${computed}",
23
"instance_count": 1,
24
"keypair": true
25
}
26
}
27
]
28
},
29
"target": {
30
"version": "2017-03-03",
31
"label": "template version label #2",
32
"description": "This template creates a sample stack with EC2 instance on AWS",
33
"vendor": {
34
"aws": {
35
"cred": "AKIAJ...DZLA",
36
"region": "ap-northeast-1"
37
}
38
},
39
"configurations": [
40
{
41
"role": "web",
42
"flag": "Web01",
43
"provision": {
44
"image": "${computed}",
45
"instance_type": "m3.medium",
46
"instance_count": 2,
47
"keypair": true
48
}
49
}
50
]
51
},
52
"diff": {
53
"new": [],
54
"removed": {
55
"configurations\/1\/provision\/volume_type": "${computed}"
56
},
57
"edited": {
58
"label": {
59
"oldvalue": "template version label #1",
60
"newvalue": "template version label #2"
61
},
62
"configurations\/provision\/instance_type": {
63
"oldvalue": "t2.micro",
64
"newvalue": "m3.medium"
65
},
66
"configurations\/provision\/instance_count": {
67
"oldvalue": 1,
68
"newvalue": 2
69
}
70
}
71
}
72
}
Copied!

Template Versions

List Mobingi Alm template versions
GET /v3/alm/template
Parameters
Type
Required
Detail
stack_id
string
Yes
The unique id returned when applying the template
Request Header
1
Authorization: Bearer eyJ0eXAiOiJQiL...CJhbGciOMeXzQfME
2
Content-Type: application/json
Copied!
Response Body
1
HTTP/1.1 200 OK
2
3
[
4
{
5
"version_id": "1kk2HiGLxF1fThVLJvC0h6fd5z3QWOiM",
6
"latest": true,
7
"last_modified": "2017-08-25T10:40:29.000Z",
8
"size": "2963"
9
},
10
{
11
"version_id": "gCn2JuPhndwxMZuodOER0yyxM8jZB6Vn",
12
"latest": false,
13
"last_modified": "2017-08-25T10:20:38.000Z",
14
"size": "211"
15
},
16
{
17
"version_id": "98O0jK5CQk8gLi14S2SLU8z3JIo3.JPx",
18
"latest": false,
19
"last_modified": "2017-08-25T08:48:12.000Z",
20
"size": "2940"
21
}
22
]
Copied!

Describe Template

Describes the template body of a specific version.
GET /v3/alm/template/{stack_id}
Parameters
Type
Required
Detail
version_id
string
No
The id of the template version associated with the stack. If empty or "latest" provided, the most updated template version is returned
Request Header
1
Authorization: Bearer eyJ0eXAiOiJQiL...CJhbGciOMeXzQfME
2
Content-Type: application/json
Copied!
Response Body
1
HTTP/1.1 200 OK
2
3
{
4
"version": "2017-03-03",
5
"label": "template version label #2",
6
"description": "This template creates a sample stack with EC2 instance on AWS",
7
"vendor": {
8
"aws": {
9
"cred": "AKIAJ...DZLA",
10
"region": "ap-northeast-1"
11
}
12
},
13
"configurations": [
14
{
15
"role": "web",
16
"flag": "Web01",
17
"provision": {
18
"image": "${computed}",
19
"instance_type": "m3.medium",
20
"instance_count": 2,
21
"keypair": true
22
}
23
}
24
]
25
}
Copied!

Stacks

List Stacks

List all stacks running under current organization account.
GET /v3/alm/stack
Request Header
1
Authorization: Bearer eyJ0eXAiOiJQiL...CJhbGciOMeXzQfME
2
Content-Type: application/json
Copied!
Response Body
1
HTTP/1.1 200 OK
2
3
[
4
{
5
"auth_token": "zQT8zJ37o9iZDIAFOVOoZzLCu0nR",
6
"user_id": "5447820c870e1",
7
"configuration": {
8
"version": "2017-03-03",
9
"label": "template version label #2",
10
"description": "This template creates a sample stack with EC2 instance on AWS",
11
"vendor": {
12
"aws": {
13
"cred": "AKIAJ...DZLA",
14
"region": "ap-northeast-1"
15
}
16
},
17
"configurations": [
18
{
19
"role": "web",
20
"flag": "Web01",
21
"provision": {
22
"image": "${computed}",
23
"instance_type": "m3.medium",
24
"instance_count": 2,
25
"keypair": true
26
}
27
}
28
]
29
},
30
"nickname": "clean sail demonstrate",
31
"create_time": "2017-08-26T19:31:25+09:00",
32
"username": "thompson",
33
"stack_id": "mo-5447820c870e1-ZgNTSRM8K-tk",
34
"stack_status": "CREATE_COMPLETE",
35
"version_id": "1kk2HiGLxF1fThVLJvC0h6fd5z3QWOiM"
36
},
37
{
38
..
39
}
40
]
Copied!

Describe Stack

Describes the stack detail information.
GET /v3/alm/stack/{stack_id}
Request Header
1
Authorization: Bearer eyJ0eXAiOiJQiL...CJhbGciOMeXzQfME
2
Content-Type: application/json
Copied!
Response Body
1
HTTP/1.1 200 OK
2
3
{
4
"auth_token": "zQT8zJ37o9iZDIAFOVOoZzLCu0nR",
5
"user_id": "5447820c870e1",
6
"configuration": {
7
"version": "2017-03-03",
8
"label": "template version label #2",
9
"description": "This template creates a sample stack with EC2 instance on AWS",
10
"vendor": {
11
"aws": {
12
"cred": "AKIAJ...DZLA",
13
"region": "ap-northeast-1"
14
}
15
},
16
"configurations": [
17
{
18
"role": "web",
19
"flag": "Web01",
20
"provision": {
21
"image": "${computed}",
22
"instance_type": "m3.medium",
23
"instance_count": 2,
24
"keypair": true
25
}
26
}
27
]
28
},
29
"nickname": "clean sail demonstrate",
30
"create_time": "2017-08-26T19:31:25+09:00",
31
"username": "thompson",
32
"stack_id": "mo-5447820c870e1-ZgNTSRM8K-tk",
33
"stack_status": "CREATE_COMPLETE",
34
"version_id": "1kk2HiGLxF1fThVLJvC0h6fd5z3QWOiM"
35
}
Copied!

Describe Container

Describes the stack container detail information.
GET /v3/alm/container/{container_id}
Parameters
Type
Required
Detail
container_id
string
Yes
The id of the container associated with the stack.
Request Header
1
Authorization: Bearer eyJ0eXAiOiJQiL...CJhbGciOMeXzQfME
2
Content-Type: application/json
Copied!
Response Body
1
HTTP/1.1 200 OK
2
3
{
4
"container_id": "i-0c32760b85f60aca7",
5
"agent_id": "e8b15d4f-f027-4c65-80f5-ded5858cd213",
6
"update_time": "1510544332",
7
"stack_id": "mo-5447820c870e1-ZgNTSRM8K-tk",
8
"instance_id": "i-0c32760b85f60aca7",
9
"status": "complete"
10
}
Copied!

List Containers

List the stack containers filtering by {stack_id} or {instance_id}
GET /v3/alm/container
Parameters
Type
Required
Detail
stack_id
string
conditional
If both {stack_id} and {instance_id} are presents, {stack_id} will be ignored.
instance_id
string
conditional
The id of the instance.
Request Header
1
Authorization: Bearer eyJ0eXAiOiJQiL...CJhbGciOMeXzQfME
2
Content-Type: application/json
Copied!
Response Body
1
HTTP/1.1 200 OK
2
3
[
4
{
5
"agent_id": "4e9a6b9a-2a1f-454e-be5e-847573b44f10",
6
"container_id": "i-049a49d8881adf122",
7
"update_time": "1510564361",
8
"stack_id": "mo-5447820c870e1-ZgNTSRM8K-tk",
9
"instance_id": "i-049a49d8881adf122",
10
"status": "complete"
11
},
12
{
13
"agent_id": "09afaa82-0a71-4680-a68a-91badaaaa134",
14
"container_id": "i-0363778be4d1bc81f",
15
"update_time": "1510564297",
16
"stack_id": "mo-5447820c870e1-ZgNTSRM8K-tk",
17
"instance_id": "i-0363778be4d1bc81f",
18
"status": "complete"
19
},
20
{
21
"agent_id": "9c075f08-81c9-4147-8974-f543640dccf6",
22
"container_id": "i-02f27fcae984fc946",
23
"update_time": "1510564348",
24
"stack_id": "mo-5447820c870e1-ZgNTSRM8K-tk",
25
"instance_id": "i-02f27fcae984fc946",
26
"status": "complete"
27
}
28
]
Copied!

RBAC

Create Role

Creates a new role. (Note: This endpoint can only be accessed by master account)
POST /v3/role
Parameters
Type
Required
Detail
name
string
Yes
Name of Mobingi Role
scope
string
Yes
Mobingi Role in json string format
Request Header
1
Authorization: Bearer eyJ0eXAiOiJQiL...CJhbGciOMeXzQfME
2
Content-Type: application/x-www-form-urlencoded
Copied!
Request body
1
{
2
"name": "sample name",
3
"scope": "{ _role scope body_ }"
Copied!
Response Body
1
HTTP/1.1 200
2
3
{
4
"status": "success",
5
"role_id": "morole-544****0e1-ZgNTSRM8K-tk"
6
}
Copied!

Update Role

Updates an existing role.
Note: This endpoint is denied to all users except master account, defined by default RBAC scope, and this scope cannot be overwritten.
PUT /v3/role/{role_id}
Parameters
Type
Required
Detail
name
string
Yes
Name of Mobingi Role
scope
string
Yes
Mobingi Role in json string format
Request Header
1
Authorization: Bearer eyJ0eXAiOiJQiL...CJhbGciOMeXzQfME
2
Content-Type: application/x-www-form-urlencoded
Copied!
Request body
1
{
2
"name": "sample name",
3
"scope": "{ _role scope body_ }"
4
}
Copied!
Response Body
1
HTTP/1.1 200
2
3
{
4
"status": "success",
5
"role_id": "morole-544****70e1-ZgNTSRM8K-tk"
6
}
Copied!

Delete Role

Deletes an existing Role.
Note: This endpoint is denied to all users except master account, defined by default RBAC scope, and this scope cannot be overwritten.
DELETE /v3/role/{role_id}
Request Header
1
Authorization: Bearer eyJ0eXAiOiJQiL...CJhbGciOMeXzQfME
2
Content-Type: application/json
Copied!
Response Body
1
HTTP/1.1 200
2
3
{
4
"status": "success",
5
"role_id": "morole-544****0e1-ZgN****M8K-tk"
6
}
Copied!

List Roles

Lists all roles created under current account.
Note: This endpoint is denied to all users except master account, defined by default RBAC scope, and this scope cannot be overwritten.
GET /v3/role
Request Header
1
Authorization: Bearer eyJ0eXAiOiJQiL...CJhbGciOMeXzQfME
2
Content-Type: application/json
Copied!
Response Body
1
HTTP/1.1 200
2
[
3
{
4
"role_id": "morole-544****0e1-ZgNT***M8K-tk",
5
"user_id": "544****0e1",
6
"name": "sample name",
7
"scope": "{ _role scope body_ }",
8
"create_time": "",
9
"update_time": ""
10
},
11
{
12
....
13
}
14
]
Copied!

Describe Roles

  1. 1.
    Describe roles attached to the user
    Lists all roles attached to a user specified by username.
    Note: This endpoint is denied to all users except master account, defined by default RBAC scope, and this scope cannot be overwritten.
    GET /v3/user/{username}/role
1
Request Header
2
```bash
3
Authorization: Bearer eyJ0eXAiOiJQiL...CJhbGciOMeXzQfME
4
Content-Type: application/json
Copied!
Response Body
1
HTTP/1.1 200
2
[
3
{
4
"role_id": "morole-544****0e1-ZgNT***M8K-tk",
5
"user_id": "544****0e1",
6
"name": "sample name",
7
"scope": "{ _role scope body_ }",
8
"create_time": "",
9
"update_time": ""
10
},
11
{
12
....
13
}
14
15
]
Copied!
1
1. **Describe Current Logged In User Roles**
2
3
```text
4
Lists all roles attached to current user.
5
6
_This endpoint is requested by users instead of master account, and returns the roles that attached to them._
7
8
<div class="callout callout-info">
9
GET <code>/v3/user/role</code>
10
</div>
11
12
13
14
Request Header
15
```bash
16
Authorization: Bearer eyJ0eXAiOiJQiL...CJhbGciOMeXzQfME
17
Content-Type: application/json
Copied!
Response Body
1
HTTP/1.1 200
2
[
3
{
4
"user_role_id": "mour-5447****0e1-TEW****dsIE-tk",
5
"role_id": "morole-5447****0e1-ZgN****RM8K-tk",
6
"user": "{ user_id: 5447****0e1, username: tes***est }",
7
"scope": "{ _role scope body_ }",
8
"create_time": "",
9
"update_time": ""
10
},
11
{
12
....
13
}
14
15
]
Copied!
1
### Attach Role to User {#rbac-attach-user-role}
2
3
Attach an existing role to a user.
4
5
**Note:** _This endpoint is denied to all users except master account, defined by_ [_default RBAC scope_](https://learn.mobingi.com/enterprise/rbac-reference#default-roles)_, and this scope cannot be overwritten._
6
7
POST `/v3/user/role`
8
9
| **Parameters** | **Type** | **Required** | **Detail** |
10
| --- | :---: | ---: | :--- |
11
| username | string | Yes | target user |
12
| role\_id | string | Yes | Mobingi Role Id |
13
14
Request Header
15
16
```bash
17
Authorization: Bearer eyJ0eXAiOiJQiL...CJhbGciOMeXzQfME
18
Content-Type: application/x-www-form-urlencoded
Copied!
Request body
1
{
2
"username": "testtest",
3
"role_id": "morole-544****0e1-ZgN****8K-tk"
4
}
Copied!
Response Body
1
HTTP/1.1 200
2
{
3
"status": "success",
4
"user_role_id": "mour-544****0e1-ZgN****M8K-tk"
5
}
Copied!

Reattach Role to User

Reattach a role to user.
Note: This endpoint is denied to all users except master account, defined by default RBAC scope, and this scope cannot be overwritten.
PUT /v3/user/role/{role_id}
Parameters
Type
Required
Detail
username
string
Yes
target user
Request Header
1
Authorization: Bearer eyJ0eXAiOiJQiL...CJhbGciOMeXzQfME
2
Content-Type: application/x-www-form-urlencoded
Copied!
Request body
1
{
2
"username": "testtest"
3
}
Copied!
Response Body
1
HTTP/1.1 200
2
3
{
4
"status": "success",
5
"role_id": "morole-5447****0e1-ZgN***M8K-tk"
6
}
Copied!

Detach Role from User

Deatch a role from user.
Note: This endpoint is denied to all users except master account, defined by default RBAC scope, and this scope cannot be overwritten.
DELETE /v3/user/role/{role_id}
Parameters
Type
Required
Detail
username
string
Yes
target user
Request Header
1
Authorization: Bearer eyJ0eXAiOiJQiL...CJhbGciOMeXzQfME
2
Content-Type: application/json
Copied!
Request body
1
{
2
"username": "testtest"
3
}
Copied!
Response Body
1
HTTP/1.1 200
2
3
{
4
"status": "success",
5
"role_id": "morole-5447****0e1-ZgN****M8K-tk"
6
}
Copied!

Describe Role Scope

Describes the role scope body.
GET /v3/role/templates
Request Header
1
Authorization: Bearer eyJ0eXAiOiJQiL...CJhbGciOMeXzQfME
2
Content-Type: application/json
Copied!
Response Body
1
HTTP/1.1 200
2
[
3
{
4
"id": "admin",
5
"name": "Management Role",
6
"scope": {
7
"version": "2017-05-05",
8
"Statement": [
9
{
10
"Effect": "Allow",
11
"Action": [
12
"*"
13
],
14
"Resource": [
15
"*"
16
]
17
}
18
]
19
}
20
},
21
{
22
....
23
}
24
]
Copied!

Alm-Agent

In this section, all endpoints are designated to work with Mobingi alm-agent in order to perform application lifecycle automation by Mobingi. Mobingi alm-agent is the Linux server side program that automatically installed during instance launch and initialization. If you are a contributor to the OSS repo github.com/mobingi/alm-agent, you're looking at the right reference here. If you are a developer working on integrating Mobingi ALM with your client applications or contributing to Mobingi API/UI only, you can ignore this API references section.

Register Agent Status

This endpoint listens to the notifications sent by Mobingi alm-agent for self status registration.
For example, when an instance is launched and Mobingi alm agent is installed, the agent will first call this endpoint to register itself.
Another example, when an AWS spot instance is scheduled to be shutdown, the agent will send notice to this endpoint and allow Mobingi system to perform other necessary actions (such as spot replacement).
POST /v3/alm/agent/agent_status
Parameters
Type
Required
Detail
stack_id
string
Yes
The stack id which this server instance is belonged to
agent_id
string
Yes
The agent's unique identifier
status
string
Yes
Sample values: starting, installing, error, notice, spot_terminate, etc..
instance_id
string
No
The server instance id where Mobingi alm-agent is installed on
message
string
No
Optional, a description of the status message, e.g: image/repository not found
Request Header
1
Authorization: Bearer eyJ0eXAiOiJQiL...CJhbGciOMeXzQfME
2
Content-Type: application/json
Copied!
Response Body
1
HTTP/1.1 202 Accepted
Copied!

Register Container Status

This endpoint listens to the notifications sent by Mobingi alm-agent with the status updates during a container's lifecycle. Possible status examples: starting, updating, restarting, running, terminated, etc.
POST /v3/alm/agent/container_status
Parameters
Type
Required
Detail
stack_id
string
Yes
The stack id which this server instance is belonged to
agent_id
string
Yes
The agent's unique identifier
container_id
string
Yes
The container unique id. _Sometimes, this value could be an instance's id.
status
string
Yes
sample values: starting, updating, restarting, running, terminated, etc..
instance_id
string
No
The server instance id where Mobingi alm-agent is installed on
Request Header
1
Authorization: Bearer eyJ0eXAiOiJQiL...CJhbGciOMeXzQfME
2
Content-Type: application/json
Copied!
Response Body
1
HTTP/1.1 202 Accepted
Copied!

Describe Container Configuration

This endpoint is used by Mobingi alm-agent to describing container section of the layer configuration from Mobingi Alm Template, identified by flag name.
GET /v3/alm/agent/config
Parameters
Type
Required
Detail
stack_id
string
Yes
the stack id where the instance is associated to
flag
string
Yes
The flag identifier of the configuration layer
Request Header
1
Authorization: Bearer eyJ0eXAiOiJQiL...CJhbGciOMeXzQfME
2
Content-Type: application/json
Copied!
Response Body
1
HTTP/1.1 200 OK
2
3
{
4
"image": "registry.mobingi.com/mobingi/ubuntu-apache2-php5",
5
"environment_variables": {
6
"Stage": "_development",
7
"DB_USERNAME": "root",
8
"DB_PSSSWORD": "7zk3FBP37",
9
"my_secret": "D3nz!lwA_h1ngt0n"
10
},
11
"gitReference": "master",
12
"gitPrivateKey": "-----BEGIN PRIVATE ...\n-----END PRIVATE KEY-----\n",
13
"gitRepo": "https://github.com/mobingilabs/default-site-php.git",
14
"updated": 1492161755
15
}
Copied!
Note: If the response has an empty body, it could mean that wrong flag name was provided, or it doesn't have any container config defined.
Last modified 1yr ago