Events module
:: services/events2 module

TODO

Methods

distribution_channel Get information about distribution channel
event_channel get information about assignment channel to event type
event_channel_preference Get user prefetences for given event type channel
event_preference get single user preference object
event_type Get information about event type
event_type_schedule get event type schedule details
event_types_index Get all events types
generate_one_time_code Generate and send one time code to user
latest_notifications Get user's notifications
notification_channels_index List of all notifiaction channels
notifications_schedule Get notifications sending schedule details
notifications_schedule_index Get all available schedules
update_event_channel Update event channel for selected event type
update_event_schedule update event type schedule
update_event_type Get information about event type
update_user_preference Update user preference object
user_preferences Get user preferences
validate_one_time_code Generate and send one time code to user

services/events2/distribution_channel

Consumer: optional Token: optional Scopes: n/a SSL: not required
https://usosapps.demo.usos.edu.pl/services/events2/distribution_channel

Get information about distribution channel

id required ID of channel
fields optional

Default value: id|name

Selector of result fields you are interested in. The selector may contain any subset of fields, which are described in the returns section.

format optional

Default value: json

Format in which to return values. See supported output formats.

callback optional

Required only if you've chosen jsonp as a return format.

Plus optional standard OAuth Consumer signing arguments: oauth_consumer_key, oauth_nonce, oauth_timestamp, oauth_signature, oauth_signature_method, oauth_version. Plus optional oauth_token for Token authorization.

Returned value:

A dictionary of selected fields and their values.

Available fields:

  • id - Unique ID of distribution channel;

  • event_type - Event type that channel is assigned to.

    This field references objects returned by event_type method. See its returns section for possible subfields (only primary are allowed).

  • name - Name of event type.

services/events2/event_channel

Consumer: optional Token: optional Scopes: n/a SSL: not required
https://usosapps.demo.usos.edu.pl/services/events2/event_channel

get information about assignment channel to event type

event_type_id required ID of event type
channel_id required ID of channel
fields optional

Default value: id|channel|event_type|is_enabled|is_mandatory|send_by_default|user_preferences

Selector of result fields you are interested in. The selector may contain any subset of fields, which are described in the returns section.

format optional

Default value: json

Format in which to return values. See supported output formats.

callback optional

Required only if you've chosen jsonp as a return format.

Plus optional standard OAuth Consumer signing arguments: oauth_consumer_key, oauth_nonce, oauth_timestamp, oauth_signature, oauth_signature_method, oauth_version. Plus optional oauth_token for Token authorization.

Returned value:

A dictionary of selected fields and their values.

Available fields:

  • id - ID of event channel;

  • channel - Assigned channel.

    This field references objects returned by distribution_channel method. See its returns section for possible subfields.

  • event_type - Assigned event type.

    This field references objects returned by event_type method. See its returns section for possible subfields (only primary are allowed).

  • is_enabled - True if sending of this kind of events is enabled;

  • is_mandatory - If true, student cannot disable receiving events of this type;

  • send_by_default - If true, user that will receive this kind of events by default;

  • user_preferences - User preferences related to event_channel.

    This field references objects returned by event_preference method. See its returns section for possible subfields (only primary are allowed).

services/events2/event_channel_preference

Consumer: required Token: required Scopes: events SSL: required
https://usosapps.demo.usos.edu.pl/services/events2/event_channel_preference

Get user prefetences for given event type channel

event_channel_id required ID of event channel
format optional

Default value: json

Format in which to return values. See supported output formats.

callback optional

Required only if you've chosen jsonp as a return format.

Plus required standard OAuth Consumer signing arguments: oauth_consumer_key, oauth_nonce, oauth_timestamp, oauth_signature, oauth_signature_method, oauth_version. Plus required oauth_token for Token authorization.

Returned value:

A dictionary of following fields and their values:

  • is_enabled - true if channell is enabled for user;

  • schedule - Chosen schedule for event.

services/events2/event_preference

Consumer: required Token: required Scopes: events SSL: required
https://usosapps.demo.usos.edu.pl/services/events2/event_preference

get single user preference object

event_channel_id required Event type schedule id
fields optional

Default value: id|schedule|is_enabled|event_channel

Selector of result fields you are interested in. The selector may contain any subset of fields, which are described in the returns section.

format optional

Default value: json

Format in which to return values. See supported output formats.

callback optional

Required only if you've chosen jsonp as a return format.

Plus required standard OAuth Consumer signing arguments: oauth_consumer_key, oauth_nonce, oauth_timestamp, oauth_signature, oauth_signature_method, oauth_version. Plus required oauth_token for Token authorization.

Returned value:

A dictionary of selected fields and their values.

Available fields:

  • Primary:

    • id - ID of an object;

    • schedule - Schedule.

      This field references objects returned by event_type_schedule method. See its returns section for possible subfields.

    • is_enabled - boolean.

  • Secondary:

    • event_channel - Event channel.

      This field references objects returned by event_channel method. See its returns section for possible subfields.

services/events2/event_type

Consumer: optional Token: optional Scopes: n/a SSL: not required
https://usosapps.demo.usos.edu.pl/services/events2/event_type

Get information about event type

id required ID of an event
fields optional

Default value: id|name|description|is_enabled|is_mandatory|send_by_default

Selector of result fields you are interested in. The selector may contain any subset of fields, which are described in the returns section.

format optional

Default value: json

Format in which to return values. See supported output formats.

callback optional

Required only if you've chosen jsonp as a return format.

Plus optional standard OAuth Consumer signing arguments: oauth_consumer_key, oauth_nonce, oauth_timestamp, oauth_signature, oauth_signature_method, oauth_version. Plus optional oauth_token for Token authorization.

Returned value:

A dictionary of selected fields and their values.

Available fields:

  • Primary:

    • id - Unique ID of event type;

    • name - Name of event type;

    • description - Description of event type;

    • is_enabled - True if sending of this kind of events is enabled;

    • is_mandatory - If true, student cannot disable receiving events of this type;

    • send_by_default - If true, user that will receive this kind of events by default;

    • default_message - If defined this message will be used as default.

  • Secondary:

    • channels - List of related channels.

      This field references objects returned by event_channel method. See its returns section for possible subfields.

    • schedules - Schedules related to channells.

      This field references objects returned by event_type_schedule method. See its returns section for possible subfields.

services/events2/event_type_schedule

Consumer: optional Token: optional Scopes: n/a SSL: not required
https://usosapps.demo.usos.edu.pl/services/events2/event_type_schedule

get event type schedule details

event_type_schedule_id required Event type schedule id
fields optional

Default value: id|schedule|is_enabled

Selector of result fields you are interested in. The selector may contain any subset of fields, which are described in the returns section.

format optional

Default value: json

Format in which to return values. See supported output formats.

callback optional

Required only if you've chosen jsonp as a return format.

Plus optional standard OAuth Consumer signing arguments: oauth_consumer_key, oauth_nonce, oauth_timestamp, oauth_signature, oauth_signature_method, oauth_version. Plus optional oauth_token for Token authorization.

Returned value:

A dictionary of selected fields and their values.

Available fields:

  • id - ID of an object;

  • schedule - Schedule.

    This field references objects returned by notifications_schedule method. See its returns section for possible subfields.

  • is_enabled - boolean.

services/events2/event_types_index

Consumer: optional Token: optional Scopes: n/a SSL: not required
https://usosapps.demo.usos.edu.pl/services/events2/event_types_index

Get all events types

fields optional

Default value: id|name|description|is_enabled|is_mandatory|send_by_default

Selector of result fields you are interested in. The selector may contain any subset of fields, which are described in the returns section of event_type method.

format optional

Default value: json

Format in which to return values. See supported output formats.

callback optional

Required only if you've chosen jsonp as a return format.

Plus optional standard OAuth Consumer signing arguments: oauth_consumer_key, oauth_nonce, oauth_timestamp, oauth_signature, oauth_signature_method, oauth_version. Plus optional oauth_token for Token authorization.

Returned value:

List of all available types

services/events2/generate_one_time_code

Consumer: required Token: required Scopes: none SSL: required
https://usosapps.demo.usos.edu.pl/services/events2/generate_one_time_code

Generate and send one time code to user

format optional

Default value: json

Format in which to return values. See supported output formats.

callback optional

Required only if you've chosen jsonp as a return format.

Plus required standard OAuth Consumer signing arguments: oauth_consumer_key, oauth_nonce, oauth_timestamp, oauth_signature, oauth_signature_method, oauth_version. Plus required oauth_token for Token authorization.

Returned value:

Unuque token used to verification of generated code

services/events2/latest_notifications

Consumer: required Token: required Scopes: events SSL: required
https://usosapps.demo.usos.edu.pl/services/events2/latest_notifications

Get user's notifications

format optional

Default value: json

Format in which to return values. See supported output formats.

callback optional

Required only if you've chosen jsonp as a return format.

Plus required standard OAuth Consumer signing arguments: oauth_consumer_key, oauth_nonce, oauth_timestamp, oauth_signature, oauth_signature_method, oauth_version. Plus required oauth_token for Token authorization.

Returned value:

List of objects

services/events2/notification_channels_index

Consumer: optional Token: optional Scopes: n/a SSL: not required
https://usosapps.demo.usos.edu.pl/services/events2/notification_channels_index

List of all notifiaction channels

fields optional

Default value: id|name|description

Selector of result fields you are interested in. The selector may contain any subset of fields, which are described in the returns section.

format optional

Default value: json

Format in which to return values. See supported output formats.

callback optional

Required only if you've chosen jsonp as a return format.

Plus optional standard OAuth Consumer signing arguments: oauth_consumer_key, oauth_nonce, oauth_timestamp, oauth_signature, oauth_signature_method, oauth_version. Plus optional oauth_token for Token authorization.

Returned value:

A dictionary of selected fields and their values.

Available fields:

  • id - ID of event channel;

  • name - Langdict object;

  • description - Langdict object.

services/events2/notifications_schedule

Consumer: optional Token: optional Scopes: n/a SSL: not required
https://usosapps.demo.usos.edu.pl/services/events2/notifications_schedule

Get notifications sending schedule details

schedule_id required ID of schedule
fields optional

Default value: id|name|days

Selector of result fields you are interested in. The selector may contain any subset of fields, which are described in the returns section.

format optional

Default value: json

Format in which to return values. See supported output formats.

callback optional

Required only if you've chosen jsonp as a return format.

Plus optional standard OAuth Consumer signing arguments: oauth_consumer_key, oauth_nonce, oauth_timestamp, oauth_signature, oauth_signature_method, oauth_version. Plus optional oauth_token for Token authorization.

Returned value:

A dictionary of selected fields and their values.

Available fields:

  • id - id of schedule;

  • name - langdict with short description of schedule;

  • days - notifications of given type will be send once per given number of days.

services/events2/notifications_schedule_index

Consumer: optional Token: optional Scopes: n/a SSL: not required
https://usosapps.demo.usos.edu.pl/services/events2/notifications_schedule_index

Get all available schedules

fields optional

Default value: id|name|days

Selector of result fields you are interested in. The selector may contain any subset of fields, which are described in the returns section of notifications_schedule method.

format optional

Default value: json

Format in which to return values. See supported output formats.

callback optional

Required only if you've chosen jsonp as a return format.

Plus optional standard OAuth Consumer signing arguments: oauth_consumer_key, oauth_nonce, oauth_timestamp, oauth_signature, oauth_signature_method, oauth_version. Plus optional oauth_token for Token authorization.

Returned value:

List of all available schedules

services/events2/update_event_channel

Consumer: optional Token: optional Scopes: n/a SSL: not required
https://usosapps.demo.usos.edu.pl/services/events2/update_event_channel

Update event channel for selected event type

body required Object is accepted as POST body
format optional

Default value: json

Format in which to return values. See supported output formats.

callback optional

Required only if you've chosen jsonp as a return format.

Plus optional standard OAuth Consumer signing arguments: oauth_consumer_key, oauth_nonce, oauth_timestamp, oauth_signature, oauth_signature_method, oauth_version. Plus optional oauth_token for Token authorization.

Returned value:

Empty dict on success

services/events2/update_event_schedule

Consumer: optional Token: optional Scopes: n/a SSL: not required
https://usosapps.demo.usos.edu.pl/services/events2/update_event_schedule

update event type schedule

body required Object is accepted as POST body
format optional

Default value: json

Format in which to return values. See supported output formats.

callback optional

Required only if you've chosen jsonp as a return format.

Plus optional standard OAuth Consumer signing arguments: oauth_consumer_key, oauth_nonce, oauth_timestamp, oauth_signature, oauth_signature_method, oauth_version. Plus optional oauth_token for Token authorization.

Returned value:

Empty dict on success

services/events2/update_event_type

Consumer: optional Token: optional Scopes: n/a SSL: not required
https://usosapps.demo.usos.edu.pl/services/events2/update_event_type

Get information about event type

body required Object is accepted as POST body
format optional

Default value: json

Format in which to return values. See supported output formats.

callback optional

Required only if you've chosen jsonp as a return format.

Plus optional standard OAuth Consumer signing arguments: oauth_consumer_key, oauth_nonce, oauth_timestamp, oauth_signature, oauth_signature_method, oauth_version. Plus optional oauth_token for Token authorization.

Returned value:

Empty dict on success

services/events2/update_user_preference

Consumer: optional Token: optional Scopes: n/a SSL: not required
https://usosapps.demo.usos.edu.pl/services/events2/update_user_preference

Update user preference object

body required Object is accepted as POST body
format optional

Default value: json

Format in which to return values. See supported output formats.

callback optional

Required only if you've chosen jsonp as a return format.

Plus optional standard OAuth Consumer signing arguments: oauth_consumer_key, oauth_nonce, oauth_timestamp, oauth_signature, oauth_signature_method, oauth_version. Plus optional oauth_token for Token authorization.

Returned value:

Empty dict on success

services/events2/user_preferences

Consumer: required Token: required Scopes: events SSL: required
https://usosapps.demo.usos.edu.pl/services/events2/user_preferences

Get user preferences

fields optional

Default value: id|schedule|is_enabled

Selector of result fields you are interested in. The selector must contain subset of primary fields, which are described in the returns section of event_preference method.

format optional

Default value: json

Format in which to return values. See supported output formats.

callback optional

Required only if you've chosen jsonp as a return format.

Plus required standard OAuth Consumer signing arguments: oauth_consumer_key, oauth_nonce, oauth_timestamp, oauth_signature, oauth_signature_method, oauth_version. Plus required oauth_token for Token authorization.

Returned value:

all user preferences

services/events2/validate_one_time_code

Consumer: required Token: required Scopes: none SSL: required
https://usosapps.demo.usos.edu.pl/services/events2/validate_one_time_code

Generate and send one time code to user

id required ID of a code
code required code to be validated
format optional

Default value: json

Format in which to return values. See supported output formats.

callback optional

Required only if you've chosen jsonp as a return format.

Plus required standard OAuth Consumer signing arguments: oauth_consumer_key, oauth_nonce, oauth_timestamp, oauth_signature, oauth_signature_method, oauth_version. Plus required oauth_token for Token authorization.

Returned value:

empty dict on success
USOS API ver. 6.5.0.0-2, 2dc34ee1, dirty (2019-09-19)