/
Adaptive Card Examples

Adaptive Card Examples

To add some of the more commonly used Adaptive Cards, copy and paste the code below in the CARD PAYLOAD EDITOR section in your new Adaptive Card.

Address

{ "type": "AdaptiveCard", "$schema": "http://adaptivecards.io/schemas/adaptive-card.json", "version": "1.3", "body": [ { "type": "Input.Text", "placeholder": "", "id": "street_1", "isRequired": true, "errorMessage": "Enter a street address", "label": "Address line 1" }, { "type": "Input.Text", "placeholder": "", "label": "Address line 2 (optional)", "id": "street_2" }, { "type": "Input.Text", "placeholder": "", "label": "City/Town", "id": "city", "isRequired": true, "errorMessage": "Enter city or town" }, { "type": "Input.ChoiceSet", "choices": [ { "value": "AL", "title": "Alabama " }, { "value": "AK", "title": "Alaska " }, { "value": "AS", "title": "American Samoa " }, { "value": "AZ", "title": "Arizona " }, { "value": "AR", "title": "Arkansas " }, { "value": "CA", "title": "California " }, { "value": "CO", "title": "Colorado " }, { "value": "CT", "title": "Connecticut " }, { "value": "DE", "title": "Delaware " }, { "value": "DC", "title": "District of Columbia " }, { "value": "FM", "title": "Federated States of Micronesia " }, { "value": "FL", "title": "Florida " }, { "value": "GA", "title": "Georgia " }, { "value": "GU", "title": "Guam " }, { "value": "HI", "title": "Hawaii " }, { "value": "ID", "title": "Idaho " }, { "value": "IL", "title": "Illinois " }, { "value": "IN", "title": "Indiana " }, { "value": "IA", "title": "Iowa " }, { "value": "KS", "title": "Kansas " }, { "value": "KY", "title": "Kentucky " }, { "value": "LA", "title": "Louisiana " }, { "value": "ME", "title": "Maine " }, { "value": "MH", "title": "Marshall Islands " }, { "value": "MD", "title": "Maryland " }, { "value": "MA", "title": "Massachusetts " }, { "value": "MI", "title": "Michigan " }, { "value": "MN", "title": "Minnesota " }, { "value": "MS", "title": "Mississippi " }, { "value": "MO", "title": "Missouri " }, { "value": "MT", "title": "Montana " }, { "value": "NE", "title": "Nebraska " }, { "value": "NV", "title": "Nevada " }, { "value": "NH", "title": "New Hampshire " }, { "value": "NJ", "title": "New Jersey " }, { "value": "NM", "title": "New Mexico " }, { "value": "NY", "title": "New York " }, { "value": "NC", "title": "North Carolina " }, { "value": "ND", "title": "North Dakota " }, { "value": "MP", "title": "Northern Mariana Islands " }, { "value": "OH", "title": "Ohio " }, { "value": "OK", "title": "Oklahoma " }, { "value": "OR", "title": "Oregon " }, { "value": "PW", "title": "Palau " }, { "value": "PA", "title": "Pennsylvania " }, { "value": "PR", "title": "Puerto Rico " }, { "value": "RI", "title": "Rhode Island " }, { "value": "SC", "title": "South Carolina " }, { "value": "SD", "title": "South Dakota " }, { "value": "TN", "title": "Tennessee " }, { "value": "TX", "title": "Texas " }, { "value": "UT", "title": "Utah " }, { "value": "VT", "title": "Vermont " }, { "value": "VI", "title": "Virgin Islands (US) " }, { "value": "VA", "title": "Virginia " }, { "value": "WA", "title": "Washington " }, { "value": "WV", "title": "West Virginia " }, { "value": "WI", "title": "Wisconsin " }, { "value": "WY", "title": "Wyoming " }, { "value": "AE", "title": "Armed Forces Europe " }, { "value": "AP", "title": "Armed Forces Pacific " }, { "value": "AA", "title": "Armed Forces Americas " } ], "placeholder": "Choose a state or U.S. territory ", "id": "stateCode", "label": "State/U.S. Territory", "isRequired": true, "errorMessage": "Select a state" }, { "type": "Input.Text", "placeholder": "5-digit zip", "id": "zipCodeValue", "maxLength": 5, "label": "ZIP Code", "isRequired": true, "errorMessage": "Enter 5 digit zip" }, { "type": "ActionSet", "id": "submitButton", "actions": [ { "type": "Action.Submit", "title": "Submit", "style": "positive", "id": "submit" } ] } ] }

 

About You

{ "type": "AdaptiveCard", "$schema": "http://adaptivecards.io/schemas/adaptive-card.json", "version": "1.3", "body": [ { "type": "ColumnSet", "columns": [ { "type": "Column", "width": "stretch", "items": [ { "type": "TextBlock", "text": "Enter your name as it appears on your legal ID.", "wrap": true }, { "type": "ColumnSet", "columns": [ { "type": "Column", "width": "stretch", "items": [ { "type": "Input.Text", "placeholder": "First Name", "id": "firstName", "value": "", "isRequired": true, "label": "First Name", "errorMessage": "Enter first name" } ] }, { "type": "Column", "width": "stretch", "items": [ { "type": "Input.Text", "placeholder": "Last Name", "id": "lastName", "label": "Last Name", "isRequired": true, "errorMessage": "Enter Last Name" } ] } ] } ] } ] }, { "type": "ColumnSet", "columns": [ { "type": "Column", "width": "stretch", "items": [ { "type": "Input.Text", "placeholder": "123 345-7689", "id": "cellPhone", "value": "", "isRequired": true, "label": "Cell Phone Number", "errorMessage": "Enter a phone number", "regex": "^(\\+\\d{1,2}\\s?)?1?\\-?\\.?\\s?\\(?\\d{3}\\)?[\\s.-]?\\d{3}[\\s.-]?\\d{4}$" } ] }, { "type": "Column", "width": "stretch", "items": [ { "type": "Input.Text", "placeholder": "MM/DD/YYYY", "id": "dateOfBirth", "label": "Date Of Birth", "isRequired": true, "regex": "^(?:(1[0-2]|0?[1-9])/(3[01]|[12][0-9]|0?[1-9])|↵ (3[01]|[12][0-9]|0?[1-9])/(1[0-2]|0?[1-9]))/(?:[0-9]{2})?[0-9]{2}$", "errorMessage": "Not a valid a valid date" } ] } ] }, { "type": "Input.Text", "placeholder": "me@example.com", "value": "", "isRequired": true, "id": "email", "label": "Email Address", "regex": "^[\\w-\\.]+@([\\w-]+\\.)+[\\w-]{2,4}$", "errorMessage": "Enter valid email" }, { "type": "ActionSet", "id": "Submit", "actions": [ { "type": "Action.Submit", "title": "Submit", "id": "submit", "style": "positive" } ] } ] }

 

Age

{ "type": "AdaptiveCard", "$schema": "http://adaptivecards.io/schemas/adaptive-card.json", "version": "1.3", "body": [ { "type": "Input.ChoiceSet", "choices": [ { "title": "Younger than 2 years old", "value": "2" }, { "title": "2-4", "value": "4" }, { "title": "5-9", "value": "9" }, { "title": "10-12", "value": "12" }, { "title": "13-17", "value": "17" }, { "title": "18-29", "value": "29" }, { "title": "30-39", "value": "39" }, { "title": "40-49", "value": "49" }, { "title": "50-59", "value": "59" }, { "title": "60-64", "value": "64" }, { "title": "65-69", "value": "69" }, { "title": "70-79", "value": "79" }, { "title": "85+", "value": "85" } ], "placeholder": "Select Age", "id": "age", "isRequired": true, "errorMessage": "You need to select an age" }, { "type": "ActionSet", "actions": [ { "type": "Action.Submit", "title": "Submit", "id": "submitAge", "style": "positive" } ] }, { "type": "ColumnSet" }, { "type": "ColumnSet" } ] }

 

Get Patient

 

Login Screen

 

Time Slot

Related content

Adaptive Cards Guide
Adaptive Cards Guide
More like this
Adaptive Card node
Adaptive Card node
More like this
Card Directive and its components
Card Directive and its components
More like this
How to call custom API after an action in Adaptive Cards
How to call custom API after an action in Adaptive Cards
More like this
Login using Adaptive cards
Login using Adaptive cards
Read with this
3.7.2 Adaptive Cards
3.7.2 Adaptive Cards
More like this