Class: CommandRequest

nationscript/requests/command~CommandRequest()

Request subclass for building requests to the commands endpoint of the API.

Stores the login credential and ensures it is sent together with the request and the pin stays up-to-date.

Constructor

new CommandRequest()

mandates the nation and c arguments.

Methods

authenticate(credential) → {this}

Provide a login credential for the nation to execute this command as.

Parameters:
Name Type Description
credential NSCredential

Login credential to use

Returns:

The request, for chaining

Type
this

(async) raw()

For a stored credential, the NSCredential#updateFromResponse method is invoked with the received response headers.