doc-exports/docs/dis/api-ref/CreateApp.html
Xiong, Chen Xiao 83fa2f6615 DIS API 20230116 version
Reviewed-by: Kacur, Michal <michal.kacur@t-systems.com>
Co-authored-by: Xiong, Chen Xiao <chenxiaoxiong@huawei.com>
Co-committed-by: Xiong, Chen Xiao <chenxiaoxiong@huawei.com>
2023-06-27 15:26:05 +00:00

118 lines
7.4 KiB
HTML

<a name="CreateApp"></a><a name="CreateApp"></a>
<h1 class="topictitle1">Creating Consumption Apps</h1>
<div id="body1039502713235"><div class="section" id="CreateApp__section1939512712311"><h4 class="sectiontitle">Function</h4><p id="CreateApp__p19395162722316">This API is used to create consumption apps.</p>
</div>
<div class="section" id="CreateApp__section18398192712237"><h4 class="sectiontitle">URI</h4><p id="CreateApp__p9399142710236">POST /v2/{project_id}/apps</p>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="CreateApp__table18401027102313" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Path Parameters</caption><thead align="left"><tr id="CreateApp__row2400122792315"><th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.2.3.2.5.1.1"><p id="CreateApp__p6401132762317">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.2.3.2.5.1.2"><p id="CreateApp__p54021627202320">Mandatory</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.2.3.2.5.1.3"><p id="CreateApp__p4402327192314">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="40%" id="mcps1.3.2.3.2.5.1.4"><p id="CreateApp__p1540332713236">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="CreateApp__row8400727132315"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.2.3.2.5.1.1 "><p id="CreateApp__p1940362710235">project_id</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.2.3.2.5.1.2 "><p id="CreateApp__p14404162742315">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.2.3.2.5.1.3 "><p id="CreateApp__p840432716235">String</p>
</td>
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.2.3.2.5.1.4 "><p id="CreateApp__p144041527122313">Project ID.</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="section" id="CreateApp__section18405112722316"><h4 class="sectiontitle">Request Parameters</h4>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="CreateApp__HeaderParameter" frame="border" border="1" rules="all"><caption><b>Table 2 </b>Request header parameters</caption><thead align="left"><tr id="CreateApp__row1240672792314"><th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.2.2.5.1.1"><p id="CreateApp__p1340722752317">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.2.2.5.1.2"><p id="CreateApp__p840712792316">Mandatory</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.2.2.5.1.3"><p id="CreateApp__p44083274234">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="40%" id="mcps1.3.3.2.2.5.1.4"><p id="CreateApp__p16409132702319">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="CreateApp__row340692732314"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.2.5.1.1 "><p id="CreateApp__p204094272231">X-Auth-Token</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.2.5.1.2 "><p id="CreateApp__p14101727152318">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.2.2.5.1.3 "><p id="CreateApp__p441022752317">String</p>
</td>
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.3.2.2.5.1.4 "><p id="CreateApp__p1412142742310">User token</p>
<p id="CreateApp__p134121427132316">The token can be obtained by calling the IAM API used to obtain a user token. The value of <strong id="CreateApp__b1412227132318">X-Subject-Token</strong> in the response header is the user token.</p>
</td>
</tr>
</tbody>
</table>
</div>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="CreateApp__request_CreateAppReq" frame="border" border="1" rules="all"><caption><b>Table 3 </b>Request body parameters</caption><thead align="left"><tr id="CreateApp__row13413132717235"><th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.3.2.5.1.1"><p id="CreateApp__p141482792317">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.3.2.5.1.2"><p id="CreateApp__p2414927112318">Mandatory</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.3.2.5.1.3"><p id="CreateApp__p3415227132320">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="40%" id="mcps1.3.3.3.2.5.1.4"><p id="CreateApp__p94152279234">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="CreateApp__row1841320278230"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.3.2.5.1.1 "><p id="CreateApp__p74169275237">app_name</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.3.2.5.1.2 "><p id="CreateApp__p441692715230">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.3.2.5.1.3 "><p id="CreateApp__p15417142712316">String</p>
</td>
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.3.3.2.5.1.4 "><p id="CreateApp__p8417152772315">Name of the consumer application to be created</p>
<p id="CreateApp__p104171527202319">The application name contains 1 to 200 characters. Only letters, digits, hyphens (-), and underscores (_) are allowed.</p>
<p id="CreateApp__p6418202713236">Minimum: <strong id="CreateApp__b1841822713234">1</strong></p>
<p id="CreateApp__p4418172720238">Maximum: <strong id="CreateApp__b164192276234">200</strong></p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="section" id="CreateApp__section74198279234"><h4 class="sectiontitle">Response Parameters</h4><p id="CreateApp__p184191227192317">None</p>
</div>
<div class="section" id="CreateApp__section541932717235"><h4 class="sectiontitle">Example Requests</h4><p id="CreateApp__p1042012715231">Creating Consumption Apps</p>
<pre class="screen" id="CreateApp__screen1842192720237">POST https://{Endpoint}/v2/{project_id}/apps
{
"app_name" : "newapp"
}</pre>
</div>
<div class="section" id="CreateApp__section1242215277233"><h4 class="sectiontitle">Example Responses</h4><p id="CreateApp__p54225279238">None</p>
</div>
<div class="section" id="CreateApp__section19423192710234"><h4 class="sectiontitle">Status Codes</h4>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="CreateApp__status_code" frame="border" border="1" rules="all"><thead align="left"><tr id="CreateApp__row3423152722312"><th align="left" class="cellrowborder" valign="top" width="15%" id="mcps1.3.7.2.1.3.1.1"><p id="CreateApp__p4424202752318">Status Code</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="85%" id="mcps1.3.7.2.1.3.1.2"><p id="CreateApp__p11425142712319">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="CreateApp__row124242273233"><td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.7.2.1.3.1.1 "><p id="CreateApp__p134251427132310">201</p>
</td>
<td class="cellrowborder" valign="top" width="85%" headers="mcps1.3.7.2.1.3.1.2 "><p id="CreateApp__p74259278231">Normal response.</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="section" id="CreateApp__section134261827192318"><h4 class="sectiontitle">Error Codes</h4><p id="CreateApp__p3426192710233">See <a href="ErrorCode.html">Error Codes</a>.</p>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="topic_300000001.html">App Management</a></div>
</div>
</div>