🖥️
carter-js v1
  • carter-js
  • 💬Conversation
    • Say
    • Interactions
    • Downvoting
    • Audio Links
    • History
  • 🎱Skills
    • Basics
  • Other Features
    • Response Times
  • More
    • Changelog
Powered by GitBook
On this page
  1. Conversation

Downvoting

Mark a carter response as offensive/innappropriate or simply non-sensical

PreviousInteractionsNextAudio Links

Last updated 2 years ago

Downvoting is explained in the . carter-js allows you to easily downvote a response by calling downvote() and passing in a number of possibilities.

// assuming you have already created a Carter object called carter

const interaction = await carter.say("Hi Carter, say something that doesn't make sense please.")
const downvoted = await carter.downvote(interaction)

downvote() returns a Boolean signifying success. The above examples passes an Interaction object to downvote(), but it can take one of three things:

  • An Interaction object

  • A ConversationEntry object (obtained through carter-js' tool)

  • A tid string

When passed either of the first two, downvote will try to extract the tid from its data. If this is not possible - likely because you passed an Interaction Object where the data property was undefined, downvote() will return false.

💬
CarterAPI Docs
history