Update Purchased App


Approve or disapprove the request and authorize or deauthorize the menus and permissions for an application.

Operation Permissions


Applications assigned with the Application Registration Administrator policy in the OU.

Request Format


POST https://{apigw-address}/enos-app-service/v2.5/apps/purchase/update

Request Parameters(URI)


Name

Location(Path/Query)

Required/Optional

Data Type

Description

orgId

Query

Required

String

The OU ID which the application belongs to. How to get orgId >>

Request Parameters(Body)


Name

Required/Optional

Data Type

Description

appId

Required

String

The application ID of this request.

organizationId

Optional

String

The OU ID which the requester belongs to.

status

Optional

Integer

The request status. 0 means the request needs to be canceled, and 2 means the request needs to be approved.

note

Optional

String

The review comments.

menus

Optional

Struct

The menus that need to be authorized or deauthorized. See Authorization Struct.

permissions

Optional

Struct

The permissions that need to be authorized or deauthorized. See Authorization Struct.

Authorization Struct


Name

Data Type

Description

checked

String Array

The IDs of the menus or permissions that need to be authorized, separated by commas.

unchecked

String Array

The IDs of the menus or permissions that need to be deauthorized, separated by commas.

Response Parameters


Name

Data Type

Description

id

String

The ID of this request.

appId

String

The application ID of this request.

organizationId

String

The OU ID which the requester belongs to.

status

Integer

The request status. 0 means the request has been rejected, and 2 means the request has been approved.

approvedNote

String

The review comments.

approvedAt

String

The time which the request has been reviewed on.

createdAt

String

The time which the request has been created on.

updatedAt

String

The time which the request has been updated on.

Samples

Request Sample


url: https://{apigw-address}/enos-app-service/v2.5/apps/purchase/update?orgId=yourOrgId
method: POST
request Body:
{
  "organizationId": "yourOUId",
  "note": "",
  "permissions": {
    "checked": [],
    "unchecked": []
  },
  "appId": "your-application-ID",
  "menus": {
    "checked": ["menu1,menu2"],
    "unchecked": ["menu3"]
  },
  "status": 2
}

Return Sample


{
  "code": 0,
  "msg": "OK",
  "subMsg": null,
  "data": {
    "id": "yourApproveID",
    "appId": "your-application-ID",
    "organizationId": "yourOUId",
    "status": 2,
    "approvedNote": "",
    "approvedAt": "2024-01-19 11:12:15",
    "createdAt": "2023-07-11 04:48:57",
    "updatedAt": "2024-01-19 11:12:15"
  }
}