Skip to content

Is it possible to use multiple tokens? #21

Answered by rigwild
toastyy00 asked this question in Q&A
Discussion options

You must be logged in to vote

Here you go. Did not test, but should hopefully works! 😁

{
  let tokens = [
    'abcdefghijklmnopqrstuvwxyz1',
    'abcdefghijklmnopqrstuvwxyz2',
    'abcdefghijklmnopqrstuvwxyz3',
    'abcdefghijklmnopqrstuvwxyz4',
    'abcdefghijklmnopqrstuvwxyz5',
    'abcdefghijklmnopqrstuvwxyz6',
    'abcdefghijklmnopqrstuvwxyz7',
    'abcdefghijklmnopqrstuvwxyz8',
    'abcdefghijklmnopqrstuvwxyz9'
  ]

  // Prevent the script from auto-updating the token when sending requests with the client
  autoUpdateToken = false

  id()
  let channelId = cid

  for (const token of tokens) {
    // Change token
    authHeader = token

    // Send a message
    let sentMessage = await api.sendMessage(channelId, '…

Replies: 2 comments 10 replies

Comment options

You must be logged in to vote
0 replies
Answer selected by toastyy00
Comment options

You must be logged in to vote
10 replies
@rigwild
Comment options

@toastyy00
Comment options

@rigwild
Comment options

@rigwild
Comment options

@toastyy00
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants