-
Notifications
You must be signed in to change notification settings - Fork 12
Class ScratchUserSession | Subcommands
Provides a read/write JSON interface with the user's "backpack", a feature of the scratch website.
Arguments:
- payload [required] - a JSON object to be uploaded.
Fails: When the server returns a malformed JSON object.
Arguments: None
Fails: When the server returns a malformed JSON object.
Provides an interface for scratch's "cloud variables" via HTTP polling (see CloudSession for TCP socket interface).
Arguments:
- var [required] - The name of the variable to be set.
- value [required] - The value which the var should be set to.
- projId [required] - The project ID of the project with the var.
Fails: When the session can't acquire a token needed for server validation.
Arguments:
- var [required] - The name of the variable to be created.
- value [required] - The value which the var should be set to.
- projId [required] - The project ID of the project with the var.
Fails: When the session can't acquire a token needed for server validation.
Arguments:
- var [required] - The name of the variable.
- projId [required] - The project ID of the project with the var.
Fails: When the variable name can't be found
Arguments:
- projId [required] - The project ID of the project to read the variables from.
Fails: When the server returns a malformed JSON object.
Allows reading of messages and message counts.
Arguments:
- user [optional, defaults to current user] - The user.
Fails: When the server returns a malformed JSON object.
Arguments: None
Fails: Should not fail.