gogol-classroom-0.4.0: Google Classroom SDK.

Copyright(c) 2015-2016 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay <brendan.g.hay@gmail.com>
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellNone
LanguageHaskell2010

Network.Google.Resource.Classroom.Courses.Patch

Contents

Description

Updates one or more fields in a course. This method returns the following error codes: * `PERMISSION_DENIED` if the requesting user is not permitted to modify the requested course or for access errors. * `NOT_FOUND` if no course exists with the requested ID. * `INVALID_ARGUMENT` if invalid fields are specified in the update mask or if no update mask is supplied. * `FAILED_PRECONDITION` for the following request errors: * CourseNotModifiable

See: Google Classroom API Reference for classroom.courses.patch.

Synopsis

REST Resource

type CoursesPatchResource = "v1" :> ("courses" :> (Capture "id" Text :> (QueryParam "$.xgafv" Xgafv :> (QueryParam "upload_protocol" Text :> (QueryParam "updateMask" GFieldMask :> (QueryParam "access_token" Text :> (QueryParam "uploadType" Text :> (QueryParam "callback" Text :> (QueryParam "alt" AltJSON :> (ReqBody '[JSON] Course :> Patch '[JSON] Course)))))))))) Source #

A resource alias for classroom.courses.patch method which the CoursesPatch request conforms to.

Creating a Request

coursesPatch Source #

Creates a value of CoursesPatch with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

data CoursesPatch Source #

Updates one or more fields in a course. This method returns the following error codes: * `PERMISSION_DENIED` if the requesting user is not permitted to modify the requested course or for access errors. * `NOT_FOUND` if no course exists with the requested ID. * `INVALID_ARGUMENT` if invalid fields are specified in the update mask or if no update mask is supplied. * `FAILED_PRECONDITION` for the following request errors: * CourseNotModifiable

See: coursesPatch smart constructor.

Instances
Eq CoursesPatch Source # 
Instance details

Defined in Network.Google.Resource.Classroom.Courses.Patch

Data CoursesPatch Source # 
Instance details

Defined in Network.Google.Resource.Classroom.Courses.Patch

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> CoursesPatch -> c CoursesPatch #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c CoursesPatch #

toConstr :: CoursesPatch -> Constr #

dataTypeOf :: CoursesPatch -> DataType #

dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c CoursesPatch) #

dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c CoursesPatch) #

gmapT :: (forall b. Data b => b -> b) -> CoursesPatch -> CoursesPatch #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> CoursesPatch -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> CoursesPatch -> r #

gmapQ :: (forall d. Data d => d -> u) -> CoursesPatch -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> CoursesPatch -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> CoursesPatch -> m CoursesPatch #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> CoursesPatch -> m CoursesPatch #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> CoursesPatch -> m CoursesPatch #

Show CoursesPatch Source # 
Instance details

Defined in Network.Google.Resource.Classroom.Courses.Patch

Generic CoursesPatch Source # 
Instance details

Defined in Network.Google.Resource.Classroom.Courses.Patch

Associated Types

type Rep CoursesPatch :: Type -> Type #

GoogleRequest CoursesPatch Source # 
Instance details

Defined in Network.Google.Resource.Classroom.Courses.Patch

Associated Types

type Rs CoursesPatch :: Type #

type Scopes CoursesPatch :: [Symbol] #

type Rep CoursesPatch Source # 
Instance details

Defined in Network.Google.Resource.Classroom.Courses.Patch

type Scopes CoursesPatch Source # 
Instance details

Defined in Network.Google.Resource.Classroom.Courses.Patch

type Scopes CoursesPatch = "https://www.googleapis.com/auth/classroom.courses" ': ([] :: [Symbol])
type Rs CoursesPatch Source # 
Instance details

Defined in Network.Google.Resource.Classroom.Courses.Patch

Request Lenses

cpUploadProtocol :: Lens' CoursesPatch (Maybe Text) Source #

Upload protocol for media (e.g. "raw", "multipart").

cpUpdateMask :: Lens' CoursesPatch (Maybe GFieldMask) Source #

Mask that identifies which fields on the course to update. This field is required to do an update. The update will fail if invalid fields are specified. The following fields are valid: * `name` * `section` * `descriptionHeading` * `description` * `room` * `courseState` * `ownerId` Note: patches to ownerId are treated as being effective immediately, but in practice it may take some time for the ownership transfer of all affected resources to complete. When set in a query parameter, this field should be specified as `updateMask=,,...`

cpUploadType :: Lens' CoursesPatch (Maybe Text) Source #

Legacy upload protocol for media (e.g. "media", "multipart").

cpPayload :: Lens' CoursesPatch Course Source #

Multipart request metadata.

cpId :: Lens' CoursesPatch Text Source #

Identifier of the course to update. This identifier can be either the Classroom-assigned identifier or an alias.