Queries permission request orders.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String Yes ListPermissionApplyOrders

The operation that you want to perform.

RegionId String Yes cn-shanghai

The region ID. For example, the ID of the China (Shanghai) region is cn-shanghai, and that of the China (Zhangjiakou) region is cn-zhangjiakou. The system determines the value of this parameter based on the endpoint that is used to call the operation.

FlowStatus Integer No 1

The status of the permission request order. Valid values:

  • 1: pending approval
  • 2: approved and authorized
  • 3: approved but authorization failed
  • 4: rejected
WorkspaceId Integer No 12345

The ID of the DataWorks workspace to which the permission request order belongs. If you do not specify the parameter, the permission request orders of all workspaces are returned. You can log on to the DataWorks console and go to the Workspace Management page to obtain the ID.

OrderType Integer Yes 1

The type of the permission request order. The parameter value is 1 and cannot be changed. This value indicates ACL-based authorization.

MaxComputeProjectName String No aMaxComputeProject

The name of the MaxCompute project to which the permission request order belongs. If you do not specify the parameter, the permission request orders of all MaxCompute projects are returned.

TableName String No aTableName

The name of the table with which the permission request order is associated. If you do not specify the parameter, the permission request orders of all tables are returned.

StartTime Long No 1616200471885

The start time. You can query all permission request orders that have been submitted after the time. The parameter value is a UNIX timestamp. If you do not specify the parameter, all permission request orders are queried.

EndTime Long No 1617200471885

The end time. You can query all permission request orders that have been submitted before the time. The parameter value is a UNIX timestamp. If you do not specify the parameter, all permission request orders that are submitted before the current time are queried.

EngineType String Yes odps

The type of the compute engine with which the permission request order is associated. The parameter value is odps and cannot be changed. This value indicates that you can request permissions only on fields of tables in MaxCompute compute engine instances.

PageNum Integer No 1

The number of the page to return. Pages start from page 1. Default value: 1.

PageSize Integer No 100

The number of entries to return on each page. Default value: 10. Maximum value: 100.

QueryType Integer Yes 1

The query type of the permission request order. Valid values:

  • 0: The permission request orders you submitted.
  • 1: The permission request orders you approved.

Response parameters

Parameter Type Example Description
RequestId String 0bc1ec92159376****

The ID of the request.

ApplyOrders Object

The query results returned by page.

PageSize Integer 10

The number of entries returned per page.

PageNumber Integer 1

The number of the returned page.

TotalCount Integer 150

The total number of permission request orders returned.

ApplyOrder Array of Orders

The list of the permission request orders.

ApplyBaseId String 267842600408993176

The unique ID of the Alibaba Cloud account that was used to submit the permission request order.

ApplyTimestamp Long 1615284086000

The time when the permission request order was submitted. The parameter value is a UNIX timestamp.

FlowId String ad8da78d-8135-455e-9486-27cf213fc140

The ID of the permission request order.

FlowStatus Integer 2

The status of the permission request order. Valid values:

  • 1: pending approval
  • 2: approved and authorized
  • 3: approved but authorization failed
  • 4: rejected
ApproveContent Object

The content of the permission request order.

ApplyReason String I need to use this table

The reason for your request. The administrator determines whether to approve the request based on the reason.

OrderType Integer 1

The type of the permission request order. The parameter value is 1 and cannot be changed. This value indicates ACL-based authorization.

ProjectMeta Object

The content of the object on which you requested permissions.

WorkspaceName String aWorkspaceName

The name of the DataWorks workspace that was associated with the MaxCompute project in which you requested permissions on a table.

ObjectMetaList Array of ObjectMetaList

The information about the object on which you requested permissions.

ObjectName String aTableName

The name of the table on which you requested permissions.

Actions Array of String Select,Describe

The permission that you wanted to request. If you wanted to request multiple permissions at the same time, separate them with commas (,).

You can request only the following permissions: Select, Describe, Drop, Alter, Update, and Download.

Examples

Sample requests

http(s)://[Endpoint]/?Action=ListPermissionApplyOrders
&FlowStatus=1
&WorkspaceId=12345
&OrderType=1
&MaxComputeProjectName=aMaxComputeProject
&TableName=aTableName
&StartTime=1616200471885
&EndTime=1617200471885
&EngineType=odps
&PageNum=1
&PageSize=100
&QueryType=1
&Common request parameters

Sample success responses

XML format

HTTP/1.1 200 OK
Content-Type:application/xml

<ListPermissionApplyOrdersResponse>
    <RequestId>0bc1ec92159376****</RequestId>
    <ApplyOrders>
        <PageSize>10</PageSize>
        <PageNumber>1</PageNumber>
        <TotalCount>150</TotalCount>
        <ApplyOrder>
            <ApplyBaseId>267842600408993176</ApplyBaseId>
            <ApplyTimestamp>1615284086000</ApplyTimestamp>
            <FlowId>ad8da78d-8135-455e-9486-27cf213fc140</FlowId>
            <FlowStatus>2</FlowStatus>
            <ApproveContent>
                <ApplyReason>I need to use this table</ApplyReason>
                <OrderType>1</OrderType>
                <ProjectMeta>
                    <WorkspaceName>aWorkspaceName</WorkspaceName>
                    <ObjectMetaList>
                        <ObjectName>aTableName</ObjectName>
                        <Actions>Select,Describe</Actions>
                    </ObjectMetaList>
                </ProjectMeta>
            </ApproveContent>
        </ApplyOrder>
    </ApplyOrders>
</ListPermissionApplyOrdersResponse>

JSON format

HTTP/1.1 200 OK
Content-Type:application/json

{
  "RequestId" : "0bc1ec92159376****",
  "ApplyOrders" : {
    "PageSize" : 10,
    "PageNumber" : 1,
    "TotalCount" : 150,
    "ApplyOrder" : {
      "ApplyBaseId" : "267842600408993176",
      "ApplyTimestamp" : 1615284086000,
      "FlowId" : "ad8da78d-8135-455e-9486-27cf213fc140",
      "FlowStatus" : 2,
      "ApproveContent" : {
        "ApplyReason" : "I need to use this table",
        "OrderType" : 1,
        "ProjectMeta" : {
          "WorkspaceName" : "aWorkspaceName",
          "ObjectMetaList" : {
            "ObjectName" : "aTableName",
            "Actions" : "Select,Describe"
          }
        }
      }
    }
  }
}

Error codes

For a list of error codes, visit the API Error Center.