Copyright | (c) 2015-2016 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay <brendan.g.hay@gmail.com> |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | None |
Language | Haskell2010 |
Creates or updates a project's policy, and returns a copy of the new policy. A policy is always updated as a whole, to avoid race conditions with concurrent policy enforcement (or management!) requests. Returns NOT_FOUND if the project does not exist, INVALID_ARGUMENT if the request is malformed.
See: Binary Authorization API Reference for binaryauthorization.projects.updatePolicy
.
Synopsis
- type ProjectsUpdatePolicyResource = "v1beta1" :> (Capture "name" Text :> (QueryParam "$.xgafv" Xgafv :> (QueryParam "upload_protocol" Text :> (QueryParam "access_token" Text :> (QueryParam "uploadType" Text :> (QueryParam "callback" Text :> (QueryParam "alt" AltJSON :> (ReqBody '[JSON] Policy :> Put '[JSON] Policy))))))))
- projectsUpdatePolicy :: Policy -> Text -> ProjectsUpdatePolicy
- data ProjectsUpdatePolicy
- pupXgafv :: Lens' ProjectsUpdatePolicy (Maybe Xgafv)
- pupUploadProtocol :: Lens' ProjectsUpdatePolicy (Maybe Text)
- pupAccessToken :: Lens' ProjectsUpdatePolicy (Maybe Text)
- pupUploadType :: Lens' ProjectsUpdatePolicy (Maybe Text)
- pupPayload :: Lens' ProjectsUpdatePolicy Policy
- pupName :: Lens' ProjectsUpdatePolicy Text
- pupCallback :: Lens' ProjectsUpdatePolicy (Maybe Text)
REST Resource
type ProjectsUpdatePolicyResource = "v1beta1" :> (Capture "name" Text :> (QueryParam "$.xgafv" Xgafv :> (QueryParam "upload_protocol" Text :> (QueryParam "access_token" Text :> (QueryParam "uploadType" Text :> (QueryParam "callback" Text :> (QueryParam "alt" AltJSON :> (ReqBody '[JSON] Policy :> Put '[JSON] Policy)))))))) Source #
A resource alias for binaryauthorization.projects.updatePolicy
method which the
ProjectsUpdatePolicy
request conforms to.
Creating a Request
Creates a value of ProjectsUpdatePolicy
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
data ProjectsUpdatePolicy Source #
Creates or updates a project's policy, and returns a copy of the new policy. A policy is always updated as a whole, to avoid race conditions with concurrent policy enforcement (or management!) requests. Returns NOT_FOUND if the project does not exist, INVALID_ARGUMENT if the request is malformed.
See: projectsUpdatePolicy
smart constructor.
Instances
Request Lenses
pupUploadProtocol :: Lens' ProjectsUpdatePolicy (Maybe Text) Source #
Upload protocol for media (e.g. "raw", "multipart").
pupAccessToken :: Lens' ProjectsUpdatePolicy (Maybe Text) Source #
OAuth access token.
pupUploadType :: Lens' ProjectsUpdatePolicy (Maybe Text) Source #
Legacy upload protocol for media (e.g. "media", "multipart").
pupPayload :: Lens' ProjectsUpdatePolicy Policy Source #
Multipart request metadata.
pupName :: Lens' ProjectsUpdatePolicy Text Source #
Output only. The resource name, in the format `projects/*/policy`. There is at most one policy per project.
pupCallback :: Lens' ProjectsUpdatePolicy (Maybe Text) Source #
JSONP