OAuthCard class
Card builder class that simplifies building oauth cards.
Constructors
OAuth |
Creates a new OAuthCard. |
Methods
button(Text |
Signin button label. |
connection |
The name of the OAuth connection to use. |
create(Chat |
Factory method for returning a message with the proper signin attachment |
text(Text |
Title of the Card. |
to |
Returns the JSON for the card, |
Constructor Details
OAuthCard(Session)
Creates a new OAuthCard.
new OAuthCard(session?: Session)
Parameters
- session
- Session
(Optional) will be used to localize any text.
Method Details
button(TextType)
connectionName(string)
The name of the OAuth connection to use.
function connectionName(name: string)
Parameters
- name
-
string
Returns
create(ChatConnector, Session, string, string, string, (err: Error, message: Message) => void)
Factory method for returning a message with the proper signin attachment
static function create(connector: ChatConnector, session: Session, connectionName: string, text: string, buttonTitle: string, done: (err: Error, message: Message) => void)
Parameters
- connector
- ChatConnector
- session
- Session
- connectionName
-
string
- text
-
string
- buttonTitle
-
string
- done
-
(err: Error, message: Message) => void
text(TextType, any[])
Title of the Card.
function text(prompts: TextType, args: any[])
Parameters
- prompts
- TextType
- args
-
any[]