我指的是以下网址上的信息。https://ibm-public-cos.github.io/crs-docs/about-compatibility-api#operations-on-buckets如上述 URL 所述,有 3 个与 IBM 云存储对象相关的对象 API 可供访问。但是,IBM CSO API 的某些 API 无法访问,例如 PUT Bucket ACL 和 GET Bucket ACL,并在使用 POSTMAN 访问它们时收到 403 错误消息。我需要有关如何访问这些 API 的信息?请提供与此相关的任何信息。任何帮助将不胜感激。
截至今天,IBM COS 支持 GET/PUT 存储桶 ACL。 如果您使用的是 Postman,下面是这些 Postman 转储的示例(显然您需要计算 Authorization
标头并使用您自己的所有信息,这只是一个教育示例(:
{
"version": 1,
"collections": [
{
"id": "ab20b534-025a-4be2-b90f-a980d4a81632",
"name": "Operations on buckets",
"folders": [],
"requests": [
{
"id": "b89a66a4-0183-43cf-9712-7c07ba615b0b",
"url": "http://endpoint/bucket-name?acl=",
"method": "PUT",
"collectionId": "ab20b534-025a-4be2-b90f-a980d4a81632",
"name": "Add a bucket ACL (canned)",
"description": "",
"headers": "x-amz-date: {timestamp}nAuthorization: {authorization-string}nx-amz-acl: public-readnContent-Type: text/plain",
"dataMode": "raw",
"data": ""
},
{
"id": "df2a9b2a-d66b-4ea6-8cfb-ab341ec23bc2",
"url": "http://endpoint/bucket-name?acl=",
"method": "PUT",
"collectionId": "ab20b534-025a-4be2-b90f-a980d4a81632",
"name": "Add a bucket ACL (custom)",
"description": "",
"headers": "x-amz-date: {timestamp}nx-amz-content-sha256: e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855nAuthorization: {authorization-string}nContent-Type: text/plain; charset=utf-8",
"dataMode": "raw",
"data": "<?xml version="1.0" encoding="UTF-8"?>n<AccessControlPolicy xmlns="http://s3.amazonaws.com/doc/2006-03-01/">n <Owner>n <ID>d4d11b981e6e489486a945d640d41c4d</ID>n <DisplayName>OwnerDisplayName1</DisplayName>n </Owner>n <AccessControlList>n <Grant>n <Grantee xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="CanonicalUser">n <ID>d4d11b981e6e489486a945d640d41c4d</ID>n <DisplayName>some-name</DisplayName>n </Grantee>n <Permission>FULL_CONTROL</Permission>n </Grant>n <Grant>n <Grantee xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="CanonicalUser">n <ID>a5c26620b0704967a72d7aeb90cf57b2</ID>n <DisplayName>some-name</DisplayName>n </Grantee>n <Permission>WRITE</Permission>n </Grant>n </AccessControlList>n</AccessControlPolicy>"
},
{
"id": "7f79523f-b9aa-46ad-abda-9ad7e37d3980",
"url": "http://bucket-name.endpoint/?acl=",
"method": "GET",
"collectionId": "ab20b534-025a-4be2-b90f-a980d4a81632",
"name": "Get a bucket ACL",
"description": "",
"headers": "x-amz-date: {timestamp}nAuthorization: {authorization-string}nContent-Type: text/plain",
"dataMode": "raw",
"data": ""
}
],
"order": [
"b89a66a4-0183-43cf-9712-7c07ba615b0b",
"df2a9b2a-d66b-4ea6-8cfb-ab341ec23bc2",
"7f79523f-b9aa-46ad-abda-9ad7e37d3980"
]
}
],
"environments": [
{
"id": "fa619322-0a84-47b5-958b-84fa4a6286ba",
"name": "API-Flow Imports",
"values": [],
"timestamp": 1497532748923
}
]
}
根据您对"云存储对象 API"的引用,我可以猜测您可能正在使用 IBM COS 的本地安装。请给我发一封电子邮件 nicholas.lange[at]ibm.com 以便我们讨论您正在寻找什么。