bungie-net-core
Version:
An easy way to interact with the Bungie.net API
102 lines (101 loc) • 5.12 kB
TypeScript
/**
* Bungie.Net API
* These endpoints constitute the functionality exposed by Bungie.net, both for more traditional website functionality and for connectivity to Bungie video games and their related functionality.
*
* Contact: support@bungie.com
*
* NOTE: This class is auto generated by the bungie-net-core code generator program
* Repository: {@link https://github.com/owens1127/bungie-net-core}
* Do not edit these files manually.
*/
import { BungieHttpProtocol } from './..';
import { BungieNetResponse } from '../interfaces/BungieNetResponse';
import { GeneralUser } from '../models/User/GeneralUser';
import { BungieCredentialType } from '../models/BungieCredentialType';
import { GetCredentialTypesForAccountResponse } from '../models/User/Models/GetCredentialTypesForAccountResponse';
import { UserTheme } from '../models/Config/UserTheme';
import { BungieMembershipType } from '../models/BungieMembershipType';
import { UserMembershipData } from '../models/User/UserMembershipData';
import { HardLinkedUserMembership } from '../models/User/HardLinkedUserMembership';
import { UserSearchResponse } from '../models/User/UserSearchResponse';
import { UserSearchPrefixRequest } from '../models/User/UserSearchPrefixRequest';
/**
* Loads a bungienet user by membership id.
* @see {@link https://bungie-net.github.io/#User.GetBungieNetUserById}
*/
export declare function getBungieNetUserById(http: BungieHttpProtocol, params: {
/** The requested Bungie.net membership id. */
id: string;
}): Promise<BungieNetResponse<GeneralUser>>;
/**
* Gets a list of all display names linked to this membership id but sanitized (
* profanity filtered). Obeys all visibility rules of calling user and is heavily
* cached.
* @see {@link https://bungie-net.github.io/#User.GetSanitizedPlatformDisplayNames}
*/
export declare function getSanitizedPlatformDisplayNames(http: BungieHttpProtocol, params: {
/** The requested membership id to load. */
membershipId: string;
}): Promise<BungieNetResponse<{
[]: string;
}>>;
/**
* Returns a list of credential types attached to the requested account
* @see {@link https://bungie-net.github.io/#User.GetCredentialTypesForTargetAccount}
*/
export declare function getCredentialTypesForTargetAccount(http: BungieHttpProtocol, params: {
/** The user's membership id */
membershipId: string;
}): Promise<BungieNetResponse<GetCredentialTypesForAccountResponse[]>>;
/**
* Returns a list of all available user themes.
* @see {@link https://bungie-net.github.io/#User.GetAvailableThemes}
*/
export declare function getAvailableThemes(http: BungieHttpProtocol): Promise<BungieNetResponse<UserTheme[]>>;
/**
* Returns a list of accounts associated with the supplied membership ID and
* membership type. This will include all linked accounts (even when hidden) if
* supplied credentials permit it.
* @see {@link https://bungie-net.github.io/#User.GetMembershipDataById}
*/
export declare function getMembershipDataById(http: BungieHttpProtocol, params: {
/** The membership ID of the target user. */
membershipId: string;
/** Type of the supplied membership ID. */
membershipType: BungieMembershipType;
}): Promise<BungieNetResponse<UserMembershipData>>;
/**
* Returns a list of accounts associated with signed in user. This is useful for
* OAuth implementations that do not give you access to the token response.
* @see {@link https://bungie-net.github.io/#User.GetMembershipDataForCurrentUser}
*/
export declare function getMembershipDataForCurrentUser(http: BungieHttpProtocol): Promise<BungieNetResponse<UserMembershipData>>;
/**
* Gets any hard linked membership given a credential. Only works for credentials
* that are public (just SteamID64 right now). Cross Save aware.
* @see {@link https://bungie-net.github.io/#User.GetMembershipFromHardLinkedCredential}
*/
export declare function getMembershipFromHardLinkedCredential(http: BungieHttpProtocol, params: {
/** The credential to look up. Must be a valid SteamID64. */
credential: string;
/** The credential type. 'SteamId' is the only valid value at present. */
crType: BungieCredentialType;
}): Promise<BungieNetResponse<HardLinkedUserMembership>>;
/**
* [OBSOLETE] Do not use this to search users, use SearchByGlobalNamePost instead.
* @see {@link https://bungie-net.github.io/#User.SearchByGlobalNamePrefix}
*/
export declare function searchByGlobalNamePrefix(http: BungieHttpProtocol, params: {
/** The display name prefix you're looking for. */
displayNamePrefix: string;
/** The zero-based page of results you desire. */
page: number;
}): Promise<BungieNetResponse<UserSearchResponse>>;
/**
* Given the prefix of a global display name, returns all users who share that name.
* @see {@link https://bungie-net.github.io/#User.SearchByGlobalNamePost}
*/
export declare function searchByGlobalNamePost(http: BungieHttpProtocol, params: {
/** The zero-based page of results you desire. */
page: number;
}, body: UserSearchPrefixRequest): Promise<BungieNetResponse<UserSearchResponse>>;