API reference

Challenges Class

Static Methods

Create ( leaderboardName , challengeOptions )
DEPRECATED. Use server-to-server API call instead.
Signature
static Request<Models.Challenge> Oculus.Platform.Challenges.Create(string leaderboardName, ChallengeOptions challengeOptions)
Parameters
leaderboardName: string
challengeOptions: ChallengeOptions
Returns
Request< Models.Challenge >
DeclineInvite ( challengeID )
If the current user has an invite to the challenge, decline the invite
Signature
static Request<Models.Challenge> Oculus.Platform.Challenges.DeclineInvite(UInt64 challengeID)
Parameters
challengeID: UInt64  The ID of challenge that the user is going to decline. It can be retrieved by Challenge.GetID().
Returns
Request< Models.Challenge >
Delete ( challengeID )
DEPRECATED. Use server-to-server API call instead.
Signature
static Request Oculus.Platform.Challenges.Delete(UInt64 challengeID)
Parameters
challengeID: UInt64
Returns
Request
Get ( challengeID )
Gets the information for a single challenge
Signature
static Request<Models.Challenge> Oculus.Platform.Challenges.Get(UInt64 challengeID)
Parameters
challengeID: UInt64  The id of the challenge whose entries to return.
Returns
Request< Models.Challenge >
GetEntries ( challengeID , limit , filter , startAt )
Requests a block of challenge entries.
Signature
static Request<Models.ChallengeEntryList> Oculus.Platform.Challenges.GetEntries(UInt64 challengeID, int limit, LeaderboardFilterType filter, LeaderboardStartAt startAt)
Parameters
challengeID: UInt64  The id of the challenge whose entries to return.
limit: int  Defines the maximum number of entries to return.
filter: LeaderboardFilterType  By using ovrLeaderboard_FilterFriends, this allows you to filter the returned values to bidirectional followers.
startAt: LeaderboardStartAt  Defines whether to center the query on the user or start at the top of the challenge.
Returns
Request< Models.ChallengeEntryList >
GetEntriesAfterRank ( challengeID , limit , afterRank )
Requests a block of challenge entries.
Signature
static Request<Models.ChallengeEntryList> Oculus.Platform.Challenges.GetEntriesAfterRank(UInt64 challengeID, int limit, ulong afterRank)
Parameters
challengeID: UInt64  The id of the challenge whose entries to return.
limit: int  The maximum number of entries to return.
afterRank: ulong  The position after which to start. For example, 10 returns challenge results starting with the 11th user.
Returns
Request< Models.ChallengeEntryList >
GetEntriesByIds ( challengeID , limit , startAt , userIDs )
Requests a block of challenge entries. Will return only entries matching the user IDs passed in.
Signature
static Request<Models.ChallengeEntryList> Oculus.Platform.Challenges.GetEntriesByIds(UInt64 challengeID, int limit, LeaderboardStartAt startAt, UInt64[] userIDs)
Parameters
challengeID: UInt64  The id of the challenge whose entries to return.
limit: int  Defines the maximum number of entries to return.
startAt: LeaderboardStartAt  Defines whether to center the query on the user or start at the top of the challenge. If this is LeaderboardStartAt.CenteredOnViewer or LeaderboardStartAt.CenteredOnViewerOrTop, then the current user's ID will be automatically added to the query.
userIDs: UInt64 []  Defines a list of user ids to get entries for.
Returns
Request< Models.ChallengeEntryList >
GetList ( challengeOptions , limit )
Requests for a list of challenge
Signature
static Request<Models.ChallengeList> Oculus.Platform.Challenges.GetList(ChallengeOptions challengeOptions, int limit)
Parameters
challengeOptions: ChallengeOptions  This indicates the options of the challenge and it can be retrieved by ChallengeOptions().
limit: int  Limits the maximum number of challenges to be fetched.
Returns
Request< Models.ChallengeList >
GetNextChallenges ( list )
Signature
static Request<Models.ChallengeList> Oculus.Platform.Challenges.GetNextChallenges(Models.ChallengeList list)
Parameters
Returns
Request< Models.ChallengeList >
GetNextEntries ( list )
Signature
static Request<Models.ChallengeEntryList> Oculus.Platform.Challenges.GetNextEntries(Models.ChallengeEntryList list)
Parameters
Returns
Request< Models.ChallengeEntryList >
GetPreviousChallenges ( list )
Signature
static Request<Models.ChallengeList> Oculus.Platform.Challenges.GetPreviousChallenges(Models.ChallengeList list)
Parameters
Returns
Request< Models.ChallengeList >
GetPreviousEntries ( list )
Signature
static Request<Models.ChallengeEntryList> Oculus.Platform.Challenges.GetPreviousEntries(Models.ChallengeEntryList list)
Parameters
Returns
Request< Models.ChallengeEntryList >
Join ( challengeID )
If the current user has permission, join the challenge
Signature
static Request<Models.Challenge> Oculus.Platform.Challenges.Join(UInt64 challengeID)
Parameters
challengeID: UInt64  The ID of challenge that the user is going to join. It can be retrieved by Challenge.GetID().
Returns
Request< Models.Challenge >
Leave ( challengeID )
If the current user has permission, leave the challenge
Signature
static Request<Models.Challenge> Oculus.Platform.Challenges.Leave(UInt64 challengeID)
Parameters
challengeID: UInt64  The ID of challenge that the user is going to leave. It can be retrieved by Challenge.GetID().
Returns
Request< Models.Challenge >
UpdateInfo ( challengeID , challengeOptions )
DEPRECATED. Use server-to-server API call instead.
Signature
static Request<Models.Challenge> Oculus.Platform.Challenges.UpdateInfo(UInt64 challengeID, ChallengeOptions challengeOptions)
Parameters
challengeID: UInt64
challengeOptions: ChallengeOptions
Returns
Request< Models.Challenge >