From 1d2d6e3add1d796b2716d1a96759ce8d411d2c2f Mon Sep 17 00:00:00 2001 From: Auralia Date: Sat, 25 Feb 2017 18:05:07 -0500 Subject: [PATCH] Bug fixes --- CHANGES.md | 4 + docs/assets/js/search.js | 2 +- docs/classes/apierror.html | 7 +- docs/classes/nsapi.html | 533 +++++++++++++++++++++++++++++++++++++ docs/globals.html | 2 +- package.json | 2 +- src/api.ts | 8 +- 7 files changed, 548 insertions(+), 10 deletions(-) diff --git a/CHANGES.md b/CHANGES.md index 101ace6..3ce2a38 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,3 +1,7 @@ +## 0.1.13 ## + +* Bug fixes + ## 0.1.12 ## * Bug fixes diff --git a/docs/assets/js/search.js b/docs/assets/js/search.js index 00ab8fb..418901d 100644 --- a/docs/assets/js/search.js +++ b/docs/assets/js/search.js @@ -1 +1 @@ -var typedoc = typedoc || {};typedoc.search = typedoc.search || {};typedoc.search.data = {"kinds":{"4":"Enumeration","16":"Enumeration member","32":"Variable","128":"Class","256":"Interface","512":"Constructor","1024":"Property","2048":"Method","262144":"Accessor"},"rows":[{"id":0,"kind":4,"name":"WorldAssemblyCouncil","url":"enums/worldassemblycouncil.html","classes":"tsd-kind-enum"},{"id":1,"kind":16,"name":"GeneralAssembly","url":"enums/worldassemblycouncil.html#generalassembly","classes":"tsd-kind-enum-member tsd-parent-kind-enum","parent":"WorldAssemblyCouncil"},{"id":2,"kind":16,"name":"SecurityCouncil","url":"enums/worldassemblycouncil.html#securitycouncil","classes":"tsd-kind-enum-member tsd-parent-kind-enum","parent":"WorldAssemblyCouncil"},{"id":3,"kind":4,"name":"TelegramType","url":"enums/telegramtype.html","classes":"tsd-kind-enum"},{"id":4,"kind":16,"name":"Recruitment","url":"enums/telegramtype.html#recruitment","classes":"tsd-kind-enum-member tsd-parent-kind-enum","parent":"TelegramType"},{"id":5,"kind":16,"name":"NonRecruitment","url":"enums/telegramtype.html#nonrecruitment","classes":"tsd-kind-enum-member tsd-parent-kind-enum","parent":"TelegramType"},{"id":6,"kind":256,"name":"PrivateShardsAuth","url":"interfaces/privateshardsauth.html","classes":"tsd-kind-interface"},{"id":7,"kind":1024,"name":"password","url":"interfaces/privateshardsauth.html#password","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"PrivateShardsAuth"},{"id":8,"kind":1024,"name":"pin","url":"interfaces/privateshardsauth.html#pin","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"PrivateShardsAuth"},{"id":9,"kind":1024,"name":"updatePin","url":"interfaces/privateshardsauth.html#updatepin","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"PrivateShardsAuth"},{"id":10,"kind":1024,"name":"autologin","url":"interfaces/privateshardsauth.html#autologin","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"PrivateShardsAuth"},{"id":11,"kind":1024,"name":"updateAutologin","url":"interfaces/privateshardsauth.html#updateautologin","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"PrivateShardsAuth"},{"id":12,"kind":128,"name":"ApiError","url":"classes/apierror.html","classes":"tsd-kind-class"},{"id":13,"kind":1024,"name":"message","url":"classes/apierror.html#message","classes":"tsd-kind-property tsd-parent-kind-class","parent":"ApiError"},{"id":14,"kind":1024,"name":"responseMetadata","url":"classes/apierror.html#responsemetadata","classes":"tsd-kind-property tsd-parent-kind-class","parent":"ApiError"},{"id":15,"kind":1024,"name":"responseText","url":"classes/apierror.html#responsetext","classes":"tsd-kind-property tsd-parent-kind-class","parent":"ApiError"},{"id":16,"kind":512,"name":"constructor","url":"classes/apierror.html#constructor","classes":"tsd-kind-constructor tsd-parent-kind-class","parent":"ApiError"},{"id":17,"kind":1024,"name":"name","url":"classes/apierror.html#name","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-inherited tsd-is-static","parent":"ApiError"},{"id":18,"kind":1024,"name":"message","url":"classes/apierror.html#message-1","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-inherited tsd-is-static","parent":"ApiError"},{"id":19,"kind":1024,"name":"stack","url":"classes/apierror.html#stack","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-inherited tsd-is-static","parent":"ApiError"},{"id":20,"kind":1024,"name":"Error","url":"classes/apierror.html#error","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-static","parent":"ApiError"},{"id":21,"kind":128,"name":"NsApi","url":"classes/nsapi.html","classes":"tsd-kind-class"},{"id":22,"kind":512,"name":"constructor","url":"classes/nsapi.html#constructor","classes":"tsd-kind-constructor tsd-parent-kind-class","parent":"NsApi"},{"id":23,"kind":262144,"name":"userAgent","url":"classes/nsapi.html#useragent","classes":"tsd-kind-accessor tsd-parent-kind-class","parent":"NsApi"},{"id":24,"kind":262144,"name":"delay","url":"classes/nsapi.html#delay","classes":"tsd-kind-accessor tsd-parent-kind-class","parent":"NsApi"},{"id":25,"kind":262144,"name":"apiDelayMillis","url":"classes/nsapi.html#apidelaymillis","classes":"tsd-kind-accessor tsd-parent-kind-class","parent":"NsApi"},{"id":26,"kind":262144,"name":"nonRecruitTgDelayMillis","url":"classes/nsapi.html#nonrecruittgdelaymillis","classes":"tsd-kind-accessor tsd-parent-kind-class","parent":"NsApi"},{"id":27,"kind":262144,"name":"recruitTgDelayMillis","url":"classes/nsapi.html#recruittgdelaymillis","classes":"tsd-kind-accessor tsd-parent-kind-class","parent":"NsApi"},{"id":28,"kind":262144,"name":"blockExistingRequests","url":"classes/nsapi.html#blockexistingrequests","classes":"tsd-kind-accessor tsd-parent-kind-class","parent":"NsApi"},{"id":29,"kind":262144,"name":"blockNewRequests","url":"classes/nsapi.html#blocknewrequests","classes":"tsd-kind-accessor tsd-parent-kind-class","parent":"NsApi"},{"id":30,"kind":262144,"name":"requestInProgress","url":"classes/nsapi.html#requestinprogress","classes":"tsd-kind-get-signature tsd-parent-kind-class","parent":"NsApi"},{"id":31,"kind":262144,"name":"requestsQueued","url":"classes/nsapi.html#requestsqueued","classes":"tsd-kind-get-signature tsd-parent-kind-class","parent":"NsApi"},{"id":32,"kind":2048,"name":"clearQueue","url":"classes/nsapi.html#clearqueue","classes":"tsd-kind-method tsd-parent-kind-class","parent":"NsApi"},{"id":33,"kind":262144,"name":"cacheApiRequests","url":"classes/nsapi.html#cacheapirequests","classes":"tsd-kind-accessor tsd-parent-kind-class","parent":"NsApi"},{"id":34,"kind":262144,"name":"cacheTime","url":"classes/nsapi.html#cachetime","classes":"tsd-kind-accessor tsd-parent-kind-class","parent":"NsApi"},{"id":35,"kind":2048,"name":"clearCache","url":"classes/nsapi.html#clearcache","classes":"tsd-kind-method tsd-parent-kind-class","parent":"NsApi"},{"id":36,"kind":2048,"name":"cleanup","url":"classes/nsapi.html#cleanup","classes":"tsd-kind-method tsd-parent-kind-class","parent":"NsApi"},{"id":37,"kind":2048,"name":"nationRequest","url":"classes/nsapi.html#nationrequest","classes":"tsd-kind-method tsd-parent-kind-class","parent":"NsApi"},{"id":38,"kind":2048,"name":"regionRequest","url":"classes/nsapi.html#regionrequest","classes":"tsd-kind-method tsd-parent-kind-class","parent":"NsApi"},{"id":39,"kind":2048,"name":"worldRequest","url":"classes/nsapi.html#worldrequest","classes":"tsd-kind-method tsd-parent-kind-class","parent":"NsApi"},{"id":40,"kind":2048,"name":"worldAssemblyRequest","url":"classes/nsapi.html#worldassemblyrequest","classes":"tsd-kind-method tsd-parent-kind-class","parent":"NsApi"},{"id":41,"kind":2048,"name":"telegramRequest","url":"classes/nsapi.html#telegramrequest","classes":"tsd-kind-method tsd-parent-kind-class","parent":"NsApi"},{"id":42,"kind":2048,"name":"authenticateRequest","url":"classes/nsapi.html#authenticaterequest","classes":"tsd-kind-method tsd-parent-kind-class","parent":"NsApi"},{"id":43,"kind":32,"name":"VERSION","url":"globals.html#version","classes":"tsd-kind-variable"},{"id":44,"kind":32,"name":"API_VERSION","url":"globals.html#api_version","classes":"tsd-kind-variable"}]}; \ No newline at end of file +var typedoc = typedoc || {};typedoc.search = typedoc.search || {};typedoc.search.data = {"kinds":{"4":"Enumeration","16":"Enumeration member","32":"Variable","128":"Class","256":"Interface","512":"Constructor","1024":"Property","2048":"Method","65536":"Type literal","262144":"Accessor"},"rows":[{"id":0,"kind":4,"name":"WorldAssemblyCouncil","url":"enums/worldassemblycouncil.html","classes":"tsd-kind-enum"},{"id":1,"kind":16,"name":"GeneralAssembly","url":"enums/worldassemblycouncil.html#generalassembly","classes":"tsd-kind-enum-member tsd-parent-kind-enum","parent":"WorldAssemblyCouncil"},{"id":2,"kind":16,"name":"SecurityCouncil","url":"enums/worldassemblycouncil.html#securitycouncil","classes":"tsd-kind-enum-member tsd-parent-kind-enum","parent":"WorldAssemblyCouncil"},{"id":3,"kind":4,"name":"TelegramType","url":"enums/telegramtype.html","classes":"tsd-kind-enum"},{"id":4,"kind":16,"name":"Recruitment","url":"enums/telegramtype.html#recruitment","classes":"tsd-kind-enum-member tsd-parent-kind-enum","parent":"TelegramType"},{"id":5,"kind":16,"name":"NonRecruitment","url":"enums/telegramtype.html#nonrecruitment","classes":"tsd-kind-enum-member tsd-parent-kind-enum","parent":"TelegramType"},{"id":6,"kind":256,"name":"PrivateShardsAuth","url":"interfaces/privateshardsauth.html","classes":"tsd-kind-interface"},{"id":7,"kind":1024,"name":"password","url":"interfaces/privateshardsauth.html#password","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"PrivateShardsAuth"},{"id":8,"kind":1024,"name":"pin","url":"interfaces/privateshardsauth.html#pin","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"PrivateShardsAuth"},{"id":9,"kind":1024,"name":"updatePin","url":"interfaces/privateshardsauth.html#updatepin","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"PrivateShardsAuth"},{"id":10,"kind":1024,"name":"autologin","url":"interfaces/privateshardsauth.html#autologin","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"PrivateShardsAuth"},{"id":11,"kind":1024,"name":"updateAutologin","url":"interfaces/privateshardsauth.html#updateautologin","classes":"tsd-kind-property tsd-parent-kind-interface","parent":"PrivateShardsAuth"},{"id":12,"kind":128,"name":"ApiError","url":"classes/apierror.html","classes":"tsd-kind-class"},{"id":13,"kind":1024,"name":"message","url":"classes/apierror.html#message","classes":"tsd-kind-property tsd-parent-kind-class","parent":"ApiError"},{"id":14,"kind":1024,"name":"responseMetadata","url":"classes/apierror.html#responsemetadata","classes":"tsd-kind-property tsd-parent-kind-class","parent":"ApiError"},{"id":15,"kind":1024,"name":"responseText","url":"classes/apierror.html#responsetext","classes":"tsd-kind-property tsd-parent-kind-class","parent":"ApiError"},{"id":16,"kind":512,"name":"constructor","url":"classes/apierror.html#constructor","classes":"tsd-kind-constructor tsd-parent-kind-class","parent":"ApiError"},{"id":17,"kind":1024,"name":"name","url":"classes/apierror.html#name","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-inherited tsd-is-static","parent":"ApiError"},{"id":18,"kind":1024,"name":"message","url":"classes/apierror.html#message-1","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-inherited tsd-is-static","parent":"ApiError"},{"id":19,"kind":1024,"name":"stack","url":"classes/apierror.html#stack","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-overwrite tsd-is-inherited tsd-is-static","parent":"ApiError"},{"id":20,"kind":1024,"name":"Error","url":"classes/apierror.html#error","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-static","parent":"ApiError"},{"id":21,"kind":128,"name":"NsApi","url":"classes/nsapi.html","classes":"tsd-kind-class"},{"id":22,"kind":1024,"name":"_userAgent","url":"classes/nsapi.html#_useragent","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"NsApi"},{"id":23,"kind":1024,"name":"_delay","url":"classes/nsapi.html#_delay","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"NsApi"},{"id":24,"kind":1024,"name":"_apiDelayMillis","url":"classes/nsapi.html#_apidelaymillis","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"NsApi"},{"id":25,"kind":1024,"name":"_recruitTgDelayMillis","url":"classes/nsapi.html#_recruittgdelaymillis","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"NsApi"},{"id":26,"kind":1024,"name":"_nonRecruitTgDelayMillis","url":"classes/nsapi.html#_nonrecruittgdelaymillis","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"NsApi"},{"id":27,"kind":1024,"name":"_queue","url":"classes/nsapi.html#_queue","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"NsApi"},{"id":28,"kind":65536,"name":"__type","url":"classes/nsapi.html#_queue.__type-1","classes":"tsd-kind-type-literal tsd-parent-kind-property tsd-is-not-exported","parent":"NsApi._queue"},{"id":29,"kind":32,"name":"tg","url":"classes/nsapi.html#_queue.__type-1.tg","classes":"tsd-kind-variable tsd-parent-kind-type-literal tsd-is-not-exported","parent":"NsApi._queue.__type"},{"id":30,"kind":32,"name":"func","url":"classes/nsapi.html#_queue.__type-1.func","classes":"tsd-kind-variable tsd-parent-kind-type-literal tsd-is-not-exported","parent":"NsApi._queue.__type"},{"id":31,"kind":65536,"name":"__type","url":"classes/nsapi.html#_queue.__type-1.func.__type-2","classes":"tsd-kind-type-literal tsd-parent-kind-variable tsd-is-not-exported","parent":"NsApi._queue.__type.func"},{"id":32,"kind":32,"name":"reject","url":"classes/nsapi.html#_queue.__type-1.reject","classes":"tsd-kind-variable tsd-parent-kind-type-literal tsd-is-not-exported","parent":"NsApi._queue.__type"},{"id":33,"kind":65536,"name":"__type","url":"classes/nsapi.html#_queue.__type-1.reject.__type-3","classes":"tsd-kind-type-literal tsd-parent-kind-variable tsd-is-not-exported","parent":"NsApi._queue.__type.reject"},{"id":34,"kind":1024,"name":"_interval","url":"classes/nsapi.html#_interval","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"NsApi"},{"id":35,"kind":1024,"name":"_lastRequestTime","url":"classes/nsapi.html#_lastrequesttime","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"NsApi"},{"id":36,"kind":1024,"name":"_lastTgTime","url":"classes/nsapi.html#_lasttgtime","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"NsApi"},{"id":37,"kind":1024,"name":"_requestInProgress","url":"classes/nsapi.html#_requestinprogress","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"NsApi"},{"id":38,"kind":1024,"name":"_cacheApiRequests","url":"classes/nsapi.html#_cacheapirequests","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"NsApi"},{"id":39,"kind":1024,"name":"_cache","url":"classes/nsapi.html#_cache","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"NsApi"},{"id":40,"kind":65536,"name":"__type","url":"classes/nsapi.html#_cache.__type","classes":"tsd-kind-type-literal tsd-parent-kind-property tsd-is-not-exported","parent":"NsApi._cache"},{"id":41,"kind":1024,"name":"_cacheTime","url":"classes/nsapi.html#_cachetime","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"NsApi"},{"id":42,"kind":1024,"name":"_blockExistingRequests","url":"classes/nsapi.html#_blockexistingrequests","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"NsApi"},{"id":43,"kind":1024,"name":"_blockNewRequests","url":"classes/nsapi.html#_blocknewrequests","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"NsApi"},{"id":44,"kind":1024,"name":"_cleanup","url":"classes/nsapi.html#_cleanup","classes":"tsd-kind-property tsd-parent-kind-class tsd-is-private","parent":"NsApi"},{"id":45,"kind":512,"name":"constructor","url":"classes/nsapi.html#constructor","classes":"tsd-kind-constructor tsd-parent-kind-class","parent":"NsApi"},{"id":46,"kind":262144,"name":"userAgent","url":"classes/nsapi.html#useragent","classes":"tsd-kind-accessor tsd-parent-kind-class","parent":"NsApi"},{"id":47,"kind":262144,"name":"delay","url":"classes/nsapi.html#delay","classes":"tsd-kind-accessor tsd-parent-kind-class","parent":"NsApi"},{"id":48,"kind":262144,"name":"apiDelayMillis","url":"classes/nsapi.html#apidelaymillis","classes":"tsd-kind-accessor tsd-parent-kind-class","parent":"NsApi"},{"id":49,"kind":262144,"name":"nonRecruitTgDelayMillis","url":"classes/nsapi.html#nonrecruittgdelaymillis","classes":"tsd-kind-accessor tsd-parent-kind-class","parent":"NsApi"},{"id":50,"kind":262144,"name":"recruitTgDelayMillis","url":"classes/nsapi.html#recruittgdelaymillis","classes":"tsd-kind-accessor tsd-parent-kind-class","parent":"NsApi"},{"id":51,"kind":262144,"name":"blockExistingRequests","url":"classes/nsapi.html#blockexistingrequests","classes":"tsd-kind-accessor tsd-parent-kind-class","parent":"NsApi"},{"id":52,"kind":262144,"name":"blockNewRequests","url":"classes/nsapi.html#blocknewrequests","classes":"tsd-kind-accessor tsd-parent-kind-class","parent":"NsApi"},{"id":53,"kind":262144,"name":"requestInProgress","url":"classes/nsapi.html#requestinprogress","classes":"tsd-kind-get-signature tsd-parent-kind-class","parent":"NsApi"},{"id":54,"kind":262144,"name":"requestsQueued","url":"classes/nsapi.html#requestsqueued","classes":"tsd-kind-get-signature tsd-parent-kind-class","parent":"NsApi"},{"id":55,"kind":2048,"name":"clearQueue","url":"classes/nsapi.html#clearqueue","classes":"tsd-kind-method tsd-parent-kind-class","parent":"NsApi"},{"id":56,"kind":262144,"name":"cacheApiRequests","url":"classes/nsapi.html#cacheapirequests","classes":"tsd-kind-accessor tsd-parent-kind-class","parent":"NsApi"},{"id":57,"kind":262144,"name":"cacheTime","url":"classes/nsapi.html#cachetime","classes":"tsd-kind-accessor tsd-parent-kind-class","parent":"NsApi"},{"id":58,"kind":2048,"name":"clearCache","url":"classes/nsapi.html#clearcache","classes":"tsd-kind-method tsd-parent-kind-class","parent":"NsApi"},{"id":59,"kind":2048,"name":"cleanup","url":"classes/nsapi.html#cleanup","classes":"tsd-kind-method tsd-parent-kind-class","parent":"NsApi"},{"id":60,"kind":2048,"name":"nationRequest","url":"classes/nsapi.html#nationrequest","classes":"tsd-kind-method tsd-parent-kind-class","parent":"NsApi"},{"id":61,"kind":2048,"name":"regionRequest","url":"classes/nsapi.html#regionrequest","classes":"tsd-kind-method tsd-parent-kind-class","parent":"NsApi"},{"id":62,"kind":2048,"name":"worldRequest","url":"classes/nsapi.html#worldrequest","classes":"tsd-kind-method tsd-parent-kind-class","parent":"NsApi"},{"id":63,"kind":2048,"name":"worldAssemblyRequest","url":"classes/nsapi.html#worldassemblyrequest","classes":"tsd-kind-method tsd-parent-kind-class","parent":"NsApi"},{"id":64,"kind":2048,"name":"telegramRequest","url":"classes/nsapi.html#telegramrequest","classes":"tsd-kind-method tsd-parent-kind-class","parent":"NsApi"},{"id":65,"kind":2048,"name":"authenticateRequest","url":"classes/nsapi.html#authenticaterequest","classes":"tsd-kind-method tsd-parent-kind-class","parent":"NsApi"},{"id":66,"kind":2048,"name":"initInterval","url":"classes/nsapi.html#initinterval","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-private","parent":"NsApi"},{"id":67,"kind":2048,"name":"xmlRequest","url":"classes/nsapi.html#xmlrequest","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-private","parent":"NsApi"},{"id":68,"kind":2048,"name":"parseXml","url":"classes/nsapi.html#parsexml","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-private","parent":"NsApi"},{"id":69,"kind":2048,"name":"apiPath","url":"classes/nsapi.html#apipath","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-private","parent":"NsApi"},{"id":70,"kind":2048,"name":"apiRequest","url":"classes/nsapi.html#apirequest","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-private","parent":"NsApi"},{"id":71,"kind":2048,"name":"toId","url":"classes/nsapi.html#toid","classes":"tsd-kind-method tsd-parent-kind-class tsd-is-private tsd-is-static","parent":"NsApi"},{"id":72,"kind":32,"name":"VERSION","url":"globals.html#version","classes":"tsd-kind-variable"},{"id":73,"kind":32,"name":"API_VERSION","url":"globals.html#api_version","classes":"tsd-kind-variable"}]}; \ No newline at end of file diff --git a/docs/classes/apierror.html b/docs/classes/apierror.html index c63040b..ce5142a 100644 --- a/docs/classes/apierror.html +++ b/docs/classes/apierror.html @@ -106,7 +106,7 @@

Properties

  • Error
  • message
  • name
  • -
  • stack
  • +
  • stack
  • @@ -244,12 +244,13 @@

    Static name

    -
    +

    Static Optional stack

    stack: string
    +
    +

    Properties

    + +

    Accessors

      @@ -110,15 +131,21 @@

      Accessors

      Methods

      @@ -235,6 +262,229 @@

      Returns +

      Properties

      +
      + +

      Private _apiDelayMillis

      +
      _apiDelayMillis: number
      + +
      +
      + +

      Private _blockExistingRequests

      +
      _blockExistingRequests: boolean
      + +
      +
      + +

      Private _blockNewRequests

      +
      _blockNewRequests: boolean
      + +
      +
      + +

      Private _cache

      +
      _cache: object
      + +
      +

      Type declaration

      +
        +
      • +
        [url: string]: object
        +
          +
        • +
          data: any
          +
        • +
        • +
          time: number
          +
        • +
        +
      • +
      +
      +
      +
      + +

      Private _cacheApiRequests

      +
      _cacheApiRequests: boolean
      + +
      +
      + +

      Private _cacheTime

      +
      _cacheTime: number
      + +
      +
      + +

      Private _cleanup

      +
      _cleanup: boolean
      + +
      +
      + +

      Private _delay

      +
      _delay: boolean
      + +
      +
      + +

      Private _interval

      +
      _interval: any
      + +
      +
      + +

      Private _lastRequestTime

      +
      _lastRequestTime: number
      + +
      +
      + +

      Private _lastTgTime

      +
      _lastTgTime: number
      + +
      +
      + +

      Private _nonRecruitTgDelayMillis

      +
      _nonRecruitTgDelayMillis: number
      + +
      +
      + +

      Private _queue

      +
      _queue: object[]
      + +
      +

      Type declaration

      +
        +
      • +
        func: function
        +
          +
        • +
            +
          • (): void
          • +
          +
            +
          • +

            Returns void

            +
          • +
          +
        • +
        +
      • +
      • +
        reject: function
        +
          +
        • +
            +
          • (err: any): void
          • +
          +
            +
          • +

            Parameters

            +
              +
            • +
              err: any
              +
            • +
            +

            Returns void

            +
          • +
          +
        • +
        +
      • +
      • +
        tg: TelegramType | undefined
        +
      • +
      +
      +
      +
      + +

      Private _recruitTgDelayMillis

      +
      _recruitTgDelayMillis: number
      + +
      +
      + +

      Private _requestInProgress

      +
      _requestInProgress: boolean
      + +
      +
      + +

      Private _userAgent

      +
      _userAgent: string
      + +
      +

    Accessors

    @@ -669,6 +919,79 @@

    Returns void

    Methods

    +
    + +

    Private apiPath

    +
      +
    • apiPath(params: string): string
    • +
    +
      +
    • + +
      +
      +

      Creates a NationStates API path from a set of parameters.

      +
      +
      +

      Parameters

      +
        +
      • +
        params: string
        +
      • +
      +

      Returns string

      +
    • +
    +
    +
    + +

    Private apiRequest

    + +
      +
    • + +
      +
      +

      Requests data from the NationStates API.

      +
      +
      +

      Parameters

      +
        +
      • +
        path: string
        +
        +

        The NationStates API path to request data from.

        +
        +
      • +
      • +
        tg: TelegramType | undefined
        +
        +

        The telegram type, or undefined if this is not a telegram + request.

        +
        +
      • +
      • +
        auth: PrivateShardsAuth | undefined
        +
        +

        Authentication information for private shards.

        +
        +
      • +
      +

      Returns Promise

      +

      A promise returning the data from the NationStates API.

      +
    • +
    +

    authenticateRequest

    @@ -785,6 +1108,28 @@

    Returns void

    +
    + +

    Private initInterval

    +
      +
    • initInterval(): void
    • +
    +
      +
    • + +
      +
      +

      Initializes the API scheduler.

      +
      +
      +

      Returns void

      +
    • +
    +

    nationRequest

    @@ -848,6 +1193,38 @@

    Returns Promise

    +
    + +

    Private parseXml

    +
      +
    • parseXml(text: string): Promise
    • +
    +
      +
    • + +
      +
      +

      Parses XML into a JSON object.

      +
      +
      +

      Parameters

      +
        +
      • +
        text: string
        +
        +

        The XML to parse.

        +
        +
      • +
      +

      Returns Promise

      +

      A promise returning a JSON object.

      +
    • +
    +

    regionRequest

    @@ -1070,6 +1447,96 @@

    Returns Promise

    +
    + +

    Private xmlRequest

    +
      +
    • xmlRequest(shards: string[], params: object, auth: PrivateShardsAuth | undefined, disableCache: boolean): Promise
    • +
    +
      +
    • + +
      +
      +

      Requests XML data from the NationStates API.

      +
      +
      +

      Parameters

      +
        +
      • +
        shards: string[]
        +
        +

        Shards to add to the NationStates API path.

        +
        +
      • +
      • +
        params: object
        +
        +

        Additional parameters to add to the NationStates API + path.

        +
        +
          +
        • +
          [name: string]: string
          +
        • +
        +
      • +
      • +
        auth: PrivateShardsAuth | undefined
        +
        +

        Authentication information for private shards.

        +
        +
      • +
      • +
        disableCache: boolean
        +
        +

        If the request cache is enabled, disable it for + this request.

        +
        +
      • +
      +

      Returns Promise

      +

      A promise returning the data from the NationStates API.

      +
    • +
    +
    +
    + +

    Static Private toId

    +
      +
    • toId(name: string): string
    • +
    +
      +
    • + +
      +
      +

      Converts names to a fixed form: all lowercase, with spaces replaced + with underscores.

      +
      +
      +

      Parameters

      +
        +
      • +
        name: string
        +
        +

        The name to convert.

        +
        +
      • +
      +

      Returns string

      +

      The converted name.

      +
    • +
    +