OneDriveJsonProtocol
A module defining data classes that correspond to the OneDrive REST API as described at https://docs.microsoft.com/en-us/onedrive/developer/rest-api/?view=odsp-graph-online.
The OneDrive REST API uses JSON as data exchange format. The classes defined here are used to read and write JSON to and from Scala objects.
In addition, the module defines converters for these data classes to enable a proper JSON serialization. They are available as implicits, which must be available in the current scope to make the conversion to and from JSON possible.
Attributes
- Graph
-
- Supertypes
-
trait DefaultJsonProtocoltrait AdditionalFormatstrait ProductFormatstrait ProductFormatsInstancestrait CollectionFormatstrait StandardFormatstrait BasicFormatsclass Objecttrait Matchableclass AnyShow all
- Self type
-
OneDriveJsonProtocol.type
Members list
Type members
Classlikes
A data class representing a drive item.
A data class representing a drive item.
Depending on the item type, specific facets are present or not. Whether the item is a file or a folder is determined by the presence or absence of the ''file'' and ''folder'' facets. Special folders are indicated by the presence of the SpecialFolder facet.
Many of these properties are read-only and are set by OneDrive.
Value parameters
- createdBy
-
identity of the actor that created this item
- createdDateTime
-
the time when this item was created
- description
-
a description of this item
- file
-
a facet with file-related information
- fileSystemInfo
-
local file system information
- folder
-
a facet with folder-related information
- id
-
the ID of this item
- lastModifiedBy
-
identity of the actor that modified this item
- lastModifiedDateTime
-
the time of the last modification
- name
-
the name of this item
- parentReference
-
the reference to the parent item
- shared
-
information about the sharing state
- size
-
the size of this item
- specialFolder
-
a facet to indicate a special folder
- webUrl
-
the URL to display this item in a browser
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
A data class representing file information. Drive items of type file contain this structure.
A data class representing file information. Drive items of type file contain this structure.
Value parameters
- hashes
-
a structure with hashes of the file's content
- mimeType
-
the auto-discovered mime type
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
A data class storing information related to the local file system of this drive item. In contrast to similar properties of the drive item structure, this data is independent on operations done via OneDrive. It can be updated by applications.
A data class storing information related to the local file system of this drive item. In contrast to similar properties of the drive item structure, this data is independent on operations done via OneDrive. It can be updated by applications.
Value parameters
- createdDateTime
-
the time of creation
- lastAccessedDateTime
-
the time of the last access (in recent file list only)
- lastModifiedDateTime
-
the time of the last modification
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
A data class representing information about a folder. Drive items of type folder contain this structure.
A data class representing information about a folder. Drive items of type folder contain this structure.
Value parameters
- childCount
-
the number of children of this folder
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
A data class representing the OneDrive JSON response for a folder request. Here we are only interested in the list with the child items of the current folder. For large folders, the content is distributed over multiple pages. In this case, a link for the next page is available.
A data class representing the OneDrive JSON response for a folder request. Here we are only interested in the list with the child items of the current folder. For large folders, the content is distributed over multiple pages. In this case, a link for the next page is available.
Value parameters
- nextLink
-
an optional link to the next page
- value
-
a list with the child items of this folder
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
A data class defining several hash values for files. An instance of this class is part of a OneDrive item that is a file.
A data class defining several hash values for files. An instance of this class is part of a OneDrive item that is a file.
Value parameters
- crc32Hash
-
CRC32 checksum as hex string
- quickXorHash
-
quick XOR hash as Base64-encoded string
- sha1Hash
-
SHA1 hash as hex string
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
A data class representing an identity. This is used to store information about actors that did something with drive items.
A data class representing an identity. This is used to store information about actors that did something with drive items.
Value parameters
- displayName
-
a human-readable name of this identity
- id
-
the ID of this identity
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
A format implementation to deal with date-time values. OneDrive uses the default ISO format that can be parsed by the ''Instant'' class. Therefore, this implementation is straight-forward.
A format implementation to deal with date-time values. OneDrive uses the default ISO format that can be parsed by the ''Instant'' class. Therefore, this implementation is straight-forward.
Attributes
- Supertypes
-
trait JsonFormat[Instant]trait JsonWriter[Instant]trait JsonReader[Instant]class Objecttrait Matchableclass AnyShow all
- Self type
-
InstantFormat.type
A data class representing a reference to another drive item.
A data class representing a reference to another drive item.
Value parameters
- driveId
-
the target drive ID
- driveType
-
the type of the drive
- id
-
the target ID
- listId
-
list ID
- name
-
the name of the target item
- path
-
the path of the target item
- shareId
-
ID of a shared resource
- siteId
-
identifier of the site
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
A data class used to generate an empty marker object in a JSON request. Such empty objects are needed for some use cases in OneDrive, e.g. to mark an item as a folder or a file. The intended usage is to have the optional property of an instance always be ''None'', so that no properties are generated.
A data class used to generate an empty marker object in a JSON request. Such empty objects are needed for some use cases in OneDrive, e.g. to mark an item as a folder or a file. The intended usage is to have the optional property of an instance always be ''None'', so that no properties are generated.
Value parameters
- optValue
-
the value, which typically should be undefined
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
A data class representing the response from the OneDrive server for a request to resolve a drive element.
A data class representing the response from the OneDrive server for a request to resolve a drive element.
Value parameters
- id
-
the ID that has been resolved
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
A data class holding information about a drive item that has been shared.
A data class holding information about a drive item that has been shared.
Value parameters
- owner
-
identity of the owner of the item
- scope
-
the scope how the item is shared
- sharedBy
-
the identity of the user who shared the item
- sharedDateTime
-
the time when the item was shared
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
A data class describing a special folder. This information is available for drive items if they represent one of the special folders.
A data class describing a special folder. This information is available for drive items if they represent one of the special folders.
Value parameters
- name
-
the name of this special folder
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
A data class to represent the response of a request to upload a chunk of a file. The upload response is different for the first chunks and the last chunk. For the last chunk, a ''DriveItem'' representation is sent, but we are only interested in the ID. The previous responses are irrelevant, so they are just ignored.
A data class to represent the response of a request to upload a chunk of a file. The upload response is different for the first chunks and the last chunk. For the last chunk, a ''DriveItem'' representation is sent, but we are only interested in the ID. The previous responses are irrelevant, so they are just ignored.
Value parameters
- id
-
the ID of the item extracted from the response
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
A data class to represent the request for an upload session.
A data class to represent the request for an upload session.
Value parameters
- item
-
the item for which content is uploaded
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
A data class representing the response of an upload session request. We are only interested in the URL where the content needs to be uploaded.
A data class representing the response of an upload session request. We are only interested in the URL where the content needs to be uploaded.
Value parameters
- uploadUrl
-
the URL to use for the following upload
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
A data class representing a drive item that is going to be newly created or updated. For such use cases, only a subset of the properties of an item can be written; these are defined here.
A data class representing a drive item that is going to be newly created or updated. For such use cases, only a subset of the properties of an item can be written; these are defined here.
Value parameters
- description
-
the description
- file
-
marker object whether this is a file
- fileSystemInfo
-
information about the local file system
- folder
-
marker object whether this is a folder
- name
-
the name of the item
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
A data class storing information related to the local file system for a drive item that is going to be created or updated. The user can fill in the fields that should be updated and leave the others undefined.
A data class storing information related to the local file system for a drive item that is going to be created or updated. The user can fill in the fields that should be updated and leave the others undefined.
Value parameters
- createdDateTime
-
the local creation time of the item
- lastAccessedDateTime
-
the access time (only in last-access list)
- lastModifiedDateTime
-
the local modified time of the item
Attributes
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all
Inherited classlikes
Attributes
- Inherited from:
- BasicFormats
- Supertypes
-
trait JsonFormat[BigDecimal]trait JsonWriter[BigDecimal]trait JsonReader[BigDecimal]class Objecttrait Matchableclass AnyShow all
Attributes
- Inherited from:
- BasicFormats
- Supertypes
-
trait JsonFormat[BigInt]trait JsonWriter[BigInt]trait JsonReader[BigInt]class Objecttrait Matchableclass AnyShow all
Attributes
- Inherited from:
- BasicFormats
- Supertypes
-
trait JsonFormat[Boolean]trait JsonWriter[Boolean]trait JsonReader[Boolean]class Objecttrait Matchableclass AnyShow all
Attributes
- Inherited from:
- BasicFormats
- Supertypes
-
trait JsonFormat[Byte]trait JsonWriter[Byte]trait JsonReader[Byte]class Objecttrait Matchableclass AnyShow all
Attributes
- Inherited from:
- BasicFormats
- Supertypes
-
trait JsonFormat[Char]trait JsonWriter[Char]trait JsonReader[Char]class Objecttrait Matchableclass AnyShow all
Attributes
- Inherited from:
- BasicFormats
- Supertypes
-
trait JsonFormat[Double]trait JsonWriter[Double]trait JsonReader[Double]class Objecttrait Matchableclass AnyShow all
Attributes
- Inherited from:
- BasicFormats
- Supertypes
-
trait JsonFormat[Float]trait JsonWriter[Float]trait JsonReader[Float]class Objecttrait Matchableclass AnyShow all
Attributes
- Inherited from:
- BasicFormats
- Supertypes
-
trait JsonFormat[Int]trait JsonWriter[Int]trait JsonReader[Int]class Objecttrait Matchableclass AnyShow all
Attributes
- Inherited from:
- AdditionalFormats
- Supertypes
-
trait JsonFormat[JsValue]trait JsonWriter[JsValue]trait JsonReader[JsValue]class Objecttrait Matchableclass AnyShow all
Attributes
- Inherited from:
- BasicFormats
- Supertypes
-
trait JsonFormat[Long]trait JsonWriter[Long]trait JsonReader[Long]class Objecttrait Matchableclass AnyShow all
Attributes
- Inherited from:
- StandardFormats
- Supertypes
-
trait JsonFormat[Option[T]]trait JsonWriter[Option[T]]trait JsonReader[Option[T]]class Objecttrait Matchableclass AnyShow all
Attributes
- Inherited from:
- AdditionalFormats
- Supertypes
-
trait RootJsonFormat[JsArray]trait RootJsonWriter[JsArray]trait RootJsonReader[JsArray]trait JsonFormat[JsArray]trait JsonWriter[JsArray]trait JsonReader[JsArray]class Objecttrait Matchableclass AnyShow all
Attributes
- Inherited from:
- AdditionalFormats
- Supertypes
-
trait RootJsonFormat[JsObject]trait RootJsonWriter[JsObject]trait RootJsonReader[JsObject]trait JsonFormat[JsObject]trait JsonWriter[JsObject]trait JsonReader[JsObject]class Objecttrait Matchableclass AnyShow all
Attributes
- Inherited from:
- BasicFormats
- Supertypes
-
trait JsonFormat[Short]trait JsonWriter[Short]trait JsonReader[Short]class Objecttrait Matchableclass AnyShow all
Attributes
- Inherited from:
- BasicFormats
- Supertypes
-
trait JsonFormat[String]trait JsonWriter[String]trait JsonReader[String]class Objecttrait Matchableclass AnyShow all
Attributes
- Inherited from:
- BasicFormats
- Supertypes
-
trait JsonFormat[Symbol]trait JsonWriter[Symbol]trait JsonReader[Symbol]class Objecttrait Matchableclass AnyShow all
Attributes
- Inherited from:
- BasicFormats
- Supertypes
-
trait JsonFormat[Unit]trait JsonWriter[Unit]trait JsonReader[Unit]class Objecttrait Matchableclass AnyShow all
Value members
Inherited methods
Constructs a JsonFormat from its two parts, JsonReader and JsonWriter.
Constructs a JsonFormat from its two parts, JsonReader and JsonWriter.
Attributes
- Inherited from:
- AdditionalFormats
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormats
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Attributes
- Inherited from:
- ProductFormatsInstances
Lazy wrapper around serialization. Useful when you want to serialize (mutually) recursive structures.
Lazy wrapper around serialization. Useful when you want to serialize (mutually) recursive structures.
Attributes
- Inherited from:
- AdditionalFormats
Turns a RootJsonReader into a RootJsonFormat that throws an UnsupportedOperationException for writes.
Turns a RootJsonReader into a RootJsonFormat that throws an UnsupportedOperationException for writes.
Attributes
- Inherited from:
- AdditionalFormats
Turns a JsonReader into a JsonFormat that throws an UnsupportedOperationException for writes.
Turns a JsonReader into a JsonFormat that throws an UnsupportedOperationException for writes.
Attributes
- Inherited from:
- AdditionalFormats
Turns a RootJsonWriter into a RootJsonFormat that throws an UnsupportedOperationException for reads.
Turns a RootJsonWriter into a RootJsonFormat that throws an UnsupportedOperationException for reads.
Attributes
- Inherited from:
- AdditionalFormats
Turns a JsonWriter into a JsonFormat that throws an UnsupportedOperationException for reads.
Turns a JsonWriter into a JsonFormat that throws an UnsupportedOperationException for reads.
Attributes
- Inherited from:
- AdditionalFormats
Explicitly turns a JsonFormat into a RootJsonFormat.
Explicitly turns a JsonFormat into a RootJsonFormat.
Attributes
- Inherited from:
- AdditionalFormats
Constructs a RootJsonFormat from its two parts, RootJsonReader and RootJsonWriter.
Constructs a RootJsonFormat from its two parts, RootJsonReader and RootJsonWriter.
Attributes
- Inherited from:
- AdditionalFormats
Wraps an existing JsonReader with Exception protection.
Wraps an existing JsonReader with Exception protection.
Attributes
- Inherited from:
- AdditionalFormats
A JsonFormat construction helper that creates a JsonFormat for an Iterable type I from a builder function List => I.
A JsonFormat construction helper that creates a JsonFormat for an Iterable type I from a builder function List => I.
Attributes
- Inherited from:
- CollectionFormats
Implicits
Implicits
Inherited implicits
Supplies the JsonFormat for Arrays.
Supplies the JsonFormat for Arrays.
Attributes
- Inherited from:
- CollectionFormats
Attributes
- Inherited from:
- StandardFormats
Attributes
- Inherited from:
- CollectionFormats
Attributes
- Inherited from:
- CollectionFormats
Attributes
- Inherited from:
- CollectionFormats
Attributes
- Inherited from:
- CollectionFormats
Attributes
- Inherited from:
- CollectionFormats
Attributes
- Inherited from:
- CollectionFormats
Attributes
- Inherited from:
- CollectionFormats
Attributes
- Inherited from:
- CollectionFormats
Supplies the JsonFormat for Lists.
Supplies the JsonFormat for Lists.
Attributes
- Inherited from:
- CollectionFormats
Supplies the JsonFormat for Maps. The implicitly available JsonFormat for the key type K must always write JsStrings, otherwise a spray.json.SerializationException will be thrown.
Supplies the JsonFormat for Maps. The implicitly available JsonFormat for the key type K must always write JsStrings, otherwise a spray.json.SerializationException will be thrown.
Attributes
- Inherited from:
- CollectionFormats
Attributes
- Inherited from:
- StandardFormats
Attributes
- Inherited from:
- CollectionFormats
Attributes
- Inherited from:
- CollectionFormats
Attributes
- Inherited from:
- StandardFormats
Attributes
- Inherited from:
- StandardFormats
Attributes
- Inherited from:
- StandardFormats
Attributes
- Inherited from:
- StandardFormats
Attributes
- Inherited from:
- StandardFormats
Attributes
- Inherited from:
- StandardFormats
Attributes
- Inherited from:
- StandardFormats
Attributes
- Inherited from:
- CollectionFormats