REST API

Profile Loader

Documentation

Code Example

// JavaScript
var $REST = require("gd-sprest");
// Get the current user's profile
$REST.ProfileLoader().getUserProfile().execute(function(profile) {
    // Code goes here
});

// TypeScript
import { ProfileLoader } from "gd-sprest";

// Get the Profile Loader
ProfileLoader()
    // Get current user's profile
    .getUserProfile()
    // Execute the request
    .execute(profile => {
        // Code goes here
    });

Methods

Name Description
createPersonalSiteEnqueueBulk(emailIDs: Array<string>) Enqueues creating a personal site for this user, which can be used to share documents, web pages, and other files.
getOwnerUserProfile() Gets the user profile of the site owner.
getUserProfile() Gets the user profile that corresponds to the current user.

Reference the User Profile Interface for the result type.