Initializes a new instance of the NsWeb class.
A string identifying you to NationStates. Using the name of your main nation is recommended.
Whether a delay is introduced before requests. Defaults to true.
The delay before requests in milliseconds. Defaults to 6000.
Allows requests immediately after this NsWeb instance is initialized.
Gets whether this NsWeb instance is blocked from performing any further requests.
Sets whether this NsWeb instance is blocked from performing any further requests.
Gets whether new requests are blocked from being added to the queue.
Sets whether new requests are blocked from being added to the queue.
Gets whether a delay is introduced before requests.
Setting this value re-initializes the scheduler.
Sets a value indicating whether a delay is introduced before requests.
Setting this value re-initializes the scheduler.
Gets the delay before requests in milliseconds.
Sets the delay before requests in milliseconds. Must be greater than or equal to 6000.
Gets whether a request is in progress.
Gets whether there is at least one request in the queue.
Gets a string identifying you to NationStates.
Sets a string identifying you to NationStates. Using the name of your main nation is recommended.
Cancels all requests in the API queue and turns off the API scheduler.
After this function is called, no further requests can be made using this API instance, including requests currently in the queue.
Cancels all requests in the queue.
Initializes the API scheduler.
Creates a POST request to the NationStates website with the specified data.
The specified data.
A promise returning the response and associated data.
Attempts to restore the specified NationStates nation using the specified password.
This call affects parts of NationStates other than the specified nation. Automating this request is a violation of NationStates script rules.
The nation name to log in with.
The password to log in with.
A void promise. An error will be thrown if restoration fails.
Converts names to a fixed form: all lowercase, with spaces replaced with underscores.
The name to convert.
The converted name.
Generated using TypeDoc
Provides access to some parts of NationStates not exposed through the standard API.