百度智能云

All Product Document

          Reference

          Enterprise Organization Management Interface

          Create Enterprise Organization

          Interface description

          Create an enterprise organization.

          The caller's account automatically becomes the master account of the organization.

          To create an enterprise organization, you need to complete the real-name authentication of the account; at the same time, there are no pending enterprise organization invitations under the account.

          Request structure

          POST /v1/organization HTTP/1.1
          Host: organization.bj.baidubce.com
          Authorization: authorization string
          
          {
              "name":"name", 
              "description": "description" 
          }

          Request header

          There are no other special headers except the public headers.

          Request parameter

          Name Type Location Description Required or not
          name String RequestBody parameter Enterprise organization name Yes
          description String RequestBody parameter Enterprise organization description No

          Response header fields

          There are no other special headers except the public headers.

          Response parameter

          Organization Object

          Request example

          POST /v1/organization
          host: organization.bj.baidubce.com
          content-type: application/json
          Content-Length: 54
          Authorization: AuthorizationString
          
          {"name":"testOrg", "description": "test organization"}

          Response example

          HTTP/1.1 201 Created
          Content-Type: application/json;charset=UTF-8
          X-Bce-Request-Id: 8d51a788-e79d-4ced-a9e0-0662ec85b7f7
          Server: BWS
          
          {
              "createTime": "2018-08-29T04:02:23Z",
              "description": "test organization",
              "id": "25fc10b3bc61437aa72b35f76515b375",
              "masterAccountId": "9fe073b94d6041c7b13617db3a52761e",
              "masterAccountMobile": "13312345678",
              "name": "testOrg"
          }

          View Enterprise Organization

          Interface description

          View your current enterprise organization.

          Request structure

          GET /v1/organization HTTP/1.1
          Host: organization.bj.baidubce.com
          Authorization: authorization string

          Request header

          There are no other special headers except the public headers.

          Request parameter

          None

          Response header fields

          There are no other special headers except the public headers.

          Response parameter

          An account can only join one enterprise organization, so there is only one record in the list; if no account group has been created or joined, an empty list is returned.

          Name Type Description
          Organizations List <Organization> Enterprise organization list

          Request example

          GET/v1/organization 
          host: organization.bj.baidubce.com
          Authorization: AuthorizationString

          Response example

          HTTP/1.1 200 OK
          Content-Type: application/json;charset=UTF-8
          X-Bce-Request-Id: 8d51a788-e79d-4ced-a9e0-0662ec85b7f7
          Server: BWS
          
          [
              {
                  "description": "",
                  "createTime": "2018-08-29T04:02:23Z",
                  "masterAccountMobile": "13312345678",
                  "masterAccountId": "9fe073b94d6041c7b13617db3a52761e",
                  "id": "25fc10b3bc61437aa72b35f76515b375",
                  "name": "test" 
              }
          ] 

          Update Enterprise Organization

          Interface description

          Modify enterprise organization information.

          Request structure

          PUT/v1/organization/{organizationId} HTTP/1.1 
          Host: organization.bj.baidubce.com
          Authorization: authorization string
          
          {
              "name": "name", 
              "description": "description" 
          }

          Request header

          There are no other special headers except the public headers.

          Request parameter

          Name Type Location Description Required or not
          organizationId String URL parameter Enterprise organization ID Yes
          name String RequestBody parameter Enterprise organization name No
          description String RequestBody parameter Enterprise organization description No

          Response header fields

          There are no other special headers except the public headers.

          Response parameter

          Organization Object

          Request example

          PUT /v1/organization/25fc10b3bc61437aa72b35f76515b375
          host: organization.bj.baidubce.com
          content-type: application/json
          Content-Length: 51
          Authorization: AuthorizationString
          
          {"name":"test", "description": "test organization"}

          Response example

          HTTP/1.1 200 OK
          Content-Type: application/json;charset=UTF-8
          X-Bce-Request-Id: bcc416b6-0bd0-4c3f-aa77-6b211bacb630
          Server: BWS
          
          {
              "description": "test organization",
              "createTime": "2018-08-29T04:02:23Z",
              "masterAccountMobile": "13312345678",
              "masterAccountId": "9fe073b94d6041c7b13617db3a52761e",
              "id": "25fc10b3bc61437aa72b35f76515b375",
              "name": "test" 
          }
          Previous
          General Description
          Next
          Account Management Interface