MCPcopy
hub / github.com/cloudfoundry/cli / assocUserWithOrgByUsername

Method assocUserWithOrgByUsername

cf/api/users.go:354–357  ·  view source on GitHub ↗
(username, orgGUID string, resource interface{})

Source from the content-addressed store, hash-verified

352}
353
354func (repo CloudControllerUserRepository) assocUserWithOrgByUsername(username, orgGUID string, resource interface{}) (apiErr error) {
355 path := fmt.Sprintf("/v2/organizations/%s/users", orgGUID)
356 return repo.ccGateway.UpdateResourceSync(repo.config.APIEndpoint(), path, usernamePayload(username), resource)
357}
358
359func (repo CloudControllerUserRepository) assocUserWithOrgByUserGUID(userGUID, orgGUID string) (apiErr error) {
360 path := fmt.Sprintf("/v2/organizations/%s/users/%s", orgGUID, userGUID)

Callers 2

SetOrgRoleByUsernameMethod · 0.95

Calls 3

usernamePayloadFunction · 0.85
UpdateResourceSyncMethod · 0.80
APIEndpointMethod · 0.65

Tested by

no test coverage detected