All Products
Search
Document Center

MaxCompute:GetProject

更新時間:Oct 24, 2024

Queries the information about a MaxCompute project.

Debugging

You can run this interface directly in OpenAPI Explorer, saving you the trouble of calculating signatures. After running successfully, OpenAPI Explorer can automatically generate SDK code samples.

Authorization information

The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:

  • Operation: the value that you can use in the Action element to specify the operation on a resource.
  • Access level: the access level of each operation. The levels are read, write, and list.
  • Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
    • The required resource types are displayed in bold characters.
    • If the permissions cannot be granted at the resource level, All Resources is used in the Resource type column of the operation.
  • Condition Key: the condition key that is defined by the cloud service.
  • Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
OperationAccess levelResource typeCondition keyAssociated operation
odps:GetProjectget
  • Project
    acs:odps:{#regionId}:{#accountId}:projects/{#ProjectName}
    none
none

Request syntax

GET /api/v1/projects/{projectName} HTTP/1.1

Request parameters

ParameterTypeRequiredDescriptionExample
projectNamestringYes

The name of the MaxCompute project.

odps_project
verbosebooleanNo

Specifies whether to use additional information.

true

Response parameters

ParameterTypeDescriptionExample
object

PopResult

requestIdstring

The ID of the request.

0b87b7b316643495896551555e855b
httpCodeinteger

Indicates whether the request was successful. If this parameter was not empty and the value of this parameter was not 200, the request failed.

200
errorCodestring

The error code.

040002
errorMsgstring

The error message.

error message.
dataobject

The returned data.

namestring

The name of the MaxCompute project.

odps_project
ownerstring

The owner of the project.

1565950907343451
typestring

The type of the project. Valid values: -managed: The project is an internal project. -external: The project is an external project.

managed
commentstring

The comment of the project.

maxcompute project
defaultQuotastring

The default computing quota.

quota_a
statusstring

The status of the project. Valid values: -AVAILABLE: The project was available. -READONLY: The project was read only. -FROZEN: The project was frozen. -DELETING: The project was being deleted.

AVAILABLE
productTypestring

The billing method of the project.

PayAsYouGo
threeTierModelboolean

Indicates whether the current project supports the three-layer model of MaxCompute.

true
costStoragestring

The storage usage.

16489027
regionIdstring

RegionID

cn-beijing
createdTimelong

Create time

1704380838000
propertiesobject

The properties of the project.

timezonestring

The time zone of the project.

Asia/Shanghai
retentionDayslong

The number of days for which backup data can be retained.

1
allowFullScanboolean

Indicates whether a full table scan on the project is enabled.

false
typeSystemstring

The data type edition. Valid values: -1: MaxCompute V1.0 data type edition. -2: MaxCompute V2.0 data type edition. -hive: Hive-compatible data type edition.

2.0
enableDecimal2boolean

Indicates whether the DECIMAL data type in MaxCompute V2.0 is enabled.

true
sqlMeteringMaxstring

The upper limit for the resources that are consumed by an SQL statement.

1500
tableLifecycleobject

The lifecycle of the table in the project.

typestring

The type of the lifecycle. Valid values: -mandatory: The lifecycle clause is required. You must configure a lifecycle for a table. -optional: The lifecycle clause is optional in a table creation statement. If you do not configure a lifecycle for a table, the table does not expire. -inherit: If you do not configure a lifecycle for a table when you create the table, the value of the odps.table.lifecycle.value parameter is used by default.

optional
valuestring

The retention period of a table. Unit: days.

37231
encryptionobject

The encryption information.

enableboolean

Indicates whether data encryption is enabled. Valid values: true and false.

true
algorithmstring

The name of the encryption algorithm.

SHA1
keystring

The key of the encryption algorithm.

dafault
tunnelQuotastring

The name of the tunnel quota.

Quota
elderTunnelQuotastring

This operation does not return a value for this parameter.

No value
enableTunnelQuotaRouteboolean

Indicates whether tunnel quota routing is enabled.

true
storageTierInfoobject

The information about the tiered storage.

storageTierSizeobject

The tiered storage.

standardSizelong

The standard storage.

27649172
longTermSizelong

The long-term storage.

21764917
lowFrequencySizelong

The IA storage.

767693
projectTotalSizelong

The total storage.

56066037
projectBackupSizelong

The backup storage.

86672917
superAdminsarray

The Super_Administrator role.

superAdminstring

The Super_Administrator role.

ALIYUN$***@aliyun.com
securityPropertiesobject

The permission properties.

usingAclboolean

Indicates whether ACL-based access control is enabled.

true
usingPolicyboolean

Indicates whether policy-based access control is enabled.

true
objectCreatorHasAccessPermissionboolean

Indicates whether the object creator is allowed to perform operations on objects.

true
objectCreatorHasGrantPermissionboolean

Indicates whether the object creator is allowed to authorize other users to perform operations on objects.

true
labelSecurityboolean

Indicates whether label-based access control is enabled.

false
enableDownloadPrivilegeboolean

Indicates whether Download control is enabled.

false
projectProtectionobject

Indicates whether project data protection is enabled.

exceptionPolicystring

The exception policy. If cross-project data access operations are required, the project owner must configure an exception policy in advance to allow the specified user to transfer data of a specified object from the current project to a specified project. After the exception policy is configured, data of the object can be transferred to the specified project even if the project data protection feature is enabled.

{ "Version": "1", "Statement": [{ "Effect":"Allow", "Principal":"<Principal>", "Action":["odps:<Action1>[, <Action2>, ...]"], "Resource":"acs:odps:*:<Resource>", "Condition":{ "StringEquals": { "odps:TaskType":["<Tasktype>"] } } }] }
protectedboolean

Indicates whether project data protection is enabled.

true
ipWhiteListobject

The IP address whitelist.

ipListstring

The list of IP addresses.

10.88.111.3
vpcIpListstring

The list of virtual private cloud (VPC) IP addresses.

10.88.111.3
saleTagobject

The tag.

resourceIdstring

The ID of the resource.

project_name
resourceTypestring

The type of the resource.

project

Examples

Sample success responses

JSONformat

{
  "requestId": "0b87b7b316643495896551555e855b",
  "httpCode": 200,
  "errorCode": "040002",
  "errorMsg": "error message.",
  "data": {
    "name": "odps_project",
    "owner": "1565950907343451",
    "type": "managed",
    "comment": "maxcompute project\n",
    "defaultQuota": "quota_a",
    "status": "AVAILABLE",
    "productType": "PayAsYouGo",
    "threeTierModel": true,
    "costStorage": "16489027",
    "regionId": "cn-beijing",
    "createdTime": 1704380838000,
    "properties": {
      "timezone": "Asia/Shanghai",
      "retentionDays": 1,
      "allowFullScan": false,
      "typeSystem": "2.0",
      "enableDecimal2": true,
      "sqlMeteringMax": "1500",
      "tableLifecycle": {
        "type": "optional",
        "value": "37231"
      },
      "encryption": {
        "enable": true,
        "algorithm": "SHA1",
        "key": "dafault"
      },
      "tunnelQuota": "Quota",
      "elderTunnelQuota": "No value\n",
      "enableTunnelQuotaRoute": true,
      "storageTierInfo": {
        "storageTierSize": {
          "standardSize": 27649172,
          "longTermSize": 21764917,
          "lowFrequencySize": 767693
        },
        "projectTotalSize": 56066037,
        "projectBackupSize": 86672917
      }
    },
    "superAdmins": [
      "ALIYUN$***@aliyun.com"
    ],
    "securityProperties": {
      "usingAcl": true,
      "usingPolicy": true,
      "objectCreatorHasAccessPermission": true,
      "objectCreatorHasGrantPermission": true,
      "labelSecurity": false,
      "enableDownloadPrivilege": false,
      "projectProtection": {
        "exceptionPolicy": "    {\n    \"Version\": \"1\",\n    \"Statement\":\n    [{\n        \"Effect\":\"Allow\",\n        \"Principal\":\"<Principal>\",\n        \"Action\":[\"odps:<Action1>[, <Action2>, ...]\"],\n        \"Resource\":\"acs:odps:*:<Resource>\",\n        \"Condition\":{\n            \"StringEquals\": {\n                \"odps:TaskType\":[\"<Tasktype>\"]\n            }\n        }\n    }]\n    }",
        "protected": true
      }
    },
    "ipWhiteList": {
      "ipList": "10.88.111.3",
      "vpcIpList": "10.88.111.3"
    },
    "saleTag": {
      "resourceId": "project_name",
      "resourceType": "project"
    }
  }
}

Error codes

For a list of error codes, visit the Service error codes.

Change history

Change timeSummary of changesOperation
2024-09-12The response structure of the API has changedView Change Details
2024-07-11The internal configuration of the API is changed, but the call is not affectedView Change Details
2024-06-25The response structure of the API has changedView Change Details
2024-06-24The response structure of the API has changedView Change Details
2024-06-24The response structure of the API has changedView Change Details
2024-04-17The response structure of the API has changedView Change Details
2024-01-08The response structure of the API has changedView Change Details
2023-12-28API Description Update. The request parameters of the API has changed. The response structure of the API has changedView Change Details
2023-11-21The response structure of the API has changedView Change Details
2023-09-21The response structure of the API has changedView Change Details
2023-09-14API Description Update. The response structure of the API has changedView Change Details