ixHello
ixHello Customer
ixHello Customer
  • About iX Hello
  • General
    • iX Hello: Create Account
    • iX Hello: Basic Mode
      • Webchat Assistant
        • Direct Chat Link
        • Embedded Chat Assistant
      • Digital Assistant
        • Digital Avatar
        • Kiosk Mode
      • Call/SMS Assistant
      • Administrative Purpose
    • iX Hello: Studio Mode
      • Prerequisites
      • Steps
        • App Creation
        • Data Source Configuration
        • AI Content Setup
        • Method Setup
        • Intent Setup
        • Slot Setup
        • Utterance Setup
        • Input Setup
        • Input Parameter Setup
        • Publish Setup
        • Test
        • Enable Call /SMS
    • Enterprise Connections
      • Generative AI
      • Internal Content
      • Microsoft Office 365
    • AI Contents
      • Add AI Content
    • Use cases
      • Contact Finder with Salesforce
        • Pre-requisites
          • An active Salesforce account
          • Lex Developer Account
          • Integrate Salesforce with iX Hello
        • Build Custom App
      • Contact Finder with REST API
        • Prerequisites
          • Integrate API Service with iX Hello
          • Lex Developer Account
        • Build Custom App
  • Apps
    • App Templates
    • NLP Custom App
    • Custom App Series - Step 1 - Building a Custom App
    • Custom App Series - Step 2 - Creating a Connection
    • Custom App Series - Step 3 - Publishing to a Channel
    • Lex Auto Publishing Setup
    • Office 365 SharePoint - Custom App
    • Office365 Exchange - Custom App
    • SalesForce Custom App
    • App Template Export & Import
    • IntentFeature BeforeAfterMethod
    • iX Hello Supported Periods Date Range
    • Shared App
    • ExecuteJS
  • Connections
    • Amazon Web Services
      • Amazon Kendra
      • Amazon Lambda
        • Amazon Lambda: Create Lambda Function
          • Amazon Lambda: iX Hello Integration
      • DynamoDB
    • Login with Amazon Setup
    • SalesForce
      • SalesForce: Create an account
      • SalesForce: Connect to iX Hello
    • Microsoft Office365 Integration Guide
    • Microsoft Office365 AAD
    • MS SQL Server
    • Twilio
  • Blueprints
    • Create App Using App Blueprints
    • Lex Bot using Appointment Blueprint
    • Domain App using Internal Data
    • Domain App S3 Data Source Setup
  • Channels
    • Amazon Alexa
      • Create Amazon Developer Account
      • Registering Alexa User Account
      • Alexa Account Linking to iX Hello
    • Amazon Lex
    • Amazon Lex Integration
    • Amazon Connect and Lex Bot Integration
  • JSON Methods
    • Internal Data JSON Methods
  • Solutions
  • AWS IAM users
  • Finding AWS Region
  • Glossary
Powered by GitBook
On this page
  • Objective
  • Pre-requisites
  • Access Key, Secret Access Key, and AWS Region Name
  • iX Hello Account
  • Steps
  • Step 1: Connect to Amazon DynamoDB
  • Step 2: Create an App for Amazon DynamoDB
  • Step 3: Create a Data Source
  • Step 4: Create Methods to fetch the data from Amazon DynamoDB
  • Scenario/ Use Case (Contact Finder):
  • Method: GetItems
  • Method: GetTables
  • Method: GetAllItems
  • Method: GetItem
  • Method: PutItem
  • Method: PostItem
  • Method: DeleteItem

Was this helpful?

  1. Connections
  2. Amazon Web Services

DynamoDB

PreviousAmazon Lambda: iX Hello IntegrationNextLogin with Amazon Setup

Last updated 7 days ago

Was this helpful?

Objective

This guide will help you to quickly connect to Amazon DynamoDB and create various methods to pull the data. The purpose is to demonstrate how easy it is to integrate an external database to iX Hello.

Pre-requisites

  • An active AWS Account

You should have an active AWS Account. If you do not have it, you can create an AWS account at

  • At least one DynamoDB table

If you do not have any DynamoDB table, you can create one quickly.

  1. Login to AWS Management Console at

  2. Enter DynamoDB into the Search Field and select the DynamoDB result.

  3. On the left side menu, select Tables and then press Create Table. For more detailed information, you can refer to the AWS official documentation

  1. Provide the Table Name Contacts and Primary Key as Id. Click on Create Table.

  1. Click on the table name Contacts in the Tables page:

  1. Now add the attributes for the table. For our demo purpose, we are going to add 3 attributes: Id, PhoneNumber, and Name. All of type String. From the Actions dropdown in the upper right, choose Create Item.

  1. Press the Add new attribute drop down in the upper right and select String. Title the new attribute Name. Repeat and add a second String attribute, PhoneNumber.

  1. Populate the item with Id 1, Name John, and PhoneNumber 123-555-1234. When finished, press Create Item

  1. Repeat the process to add more data. e.g.

{ "id": 2, "Name": "Mike", "PhoneNumber": "123-555-6789" }

Access Key, Secret Access Key, and AWS Region Name

To be able to connect to Amazon DynamoDB from iX Hello, one IAM user is required and that user should have permissions to view/add/edit/delete the DynamoDB data. It is recommended to have an IAM policy named AmazonDynamoDBFullAccess be assigned to the user.

iX Hello Account

Steps

Before proceeding with these steps, you should have all the prerequisites satisfied.

Step 1: Connect to Amazon DynamoDB

  1. To configure DynamoDB, browse to: Integration > Connect System > Connections Gallery.

  1. From the Gallery, scroll down and select DynamoDB

  1. Press Connect. The Configuration screen will open where you need to provide connection information as shown below.

If you do not have this information ready, please refer to the pre-requisites above

The table below explains each of the inputs shown on this screen.

Input

Information

Service Instance Name

You can give any value of your choice.

Consumer Key

This is your AWS Access key ID

Consumer Secret

This is your AWS Secret access key

Region

AWS Region Name. Your DynamoDB table should be in this region.

Example: us-east-1, us-east-2, us-west-1, us-west-2

  1. After entering the information, click on Validate and Save Settings. If the input is correct, a Success message will appear and the integration will be saved. A listing will appear on the Integrations listing page as shown below.

Step 2: Create an App for Amazon DynamoDB

  1. To create an app, browse to Apps > Custom Apps and click on New Custom App button as shown below.

  1. You should see a small popup as shown below.

Populate the fields as follows:

Name

You can give any value of your choice.

Custom App Type

Select Search

Category

Default.

  1. Click on Save. This will create a new App.

Step 3: Create a Data Source

A data source connects an app with the DynamoDB integration we did earlier.

  1. Once you have created an App, go to Data Sources by opening the App, opening the Data Sources tab, and clicking Create New Data Source.

  1. You should see a popup screen as shown below

  1. Give the DataSource a name of your choice and make sure you select the DynamoDB integration created earlier. Click Save. You should now see the new Data Source listed.

Once a data source is created, you are ready to start creating various methods.

Step 4: Create Methods to fetch the data from Amazon DynamoDB

To use this step, make sure you have completed previous step. If not go back and complete it.

Methods allows you to fetch data from the DynamoDB table. To access the methods, click on the Methods tab, make sure the correct DataSource shows in the Select DataSource window, and press Create New Method.

As of the publication date of this document, iX Hello supports following DynamoDB methods:

  1. Get Tables

  2. Get All Items

  3. Get Item

  4. Get Items

  5. Put Item

  6. Post Item

  7. Delete Item

Depending on requirement, you will have to use an appropriate method, this document will explain each of these methods with an example.

Let’s start with a use case.

Scenario/ Use Case (Contact Finder):

You have a DynamoDB table which is used to store all the contacts in your organization. If you are using this for personal use, then consider that table contains contact details of your friends and family members.

You want to find email address of your friend Sam. For this, you can use GetItems method as explained below.

Method: GetItems

This method returns a database entry based on a parameter value (Name). It requires two input parameters as explained below. Open Method Inputs:

Parameters:

Parameter

Sample Value

Info

Method Name

Get Items

Name of the metho

Request Type

GetItems

Pre-defined method

TableName

Contact

(Select from the drop-down list, you do not have to remember it)

DynamoDB table name. (Case Sensitive)

QueryParameters

Example: 1 {"Name":"John"}

Example: 2 {"Name":"Smith"}

Key Value pair in a valid JSON format. (Case Sensitive)

To format the output, open the Method Output tab:

Parameter
Info

Result Type

Format of return values

Record Limit

Numeric value (e.g. 10)

If Method is returning larger number of records, then you can limit this result by providing this value.

Method Result displays options on how to present the returned values:

Parameter

Info

Record JsonPath

Each method returns data in JSON format and to pick any specific information from the JSON, we need to specify the Record JsonPath so the platform will pick that data in consideration while displaying results.

Example: $.[*]

This option returns all the records.

Valid Result Template

This indicates how results should be represented if proper values have been returned. For example:

Here you go, {{Records}}

where {{Records}} represents one or more records separated by a separator.

Record Template

Describes how to display a record that may have more than one parameter. For example, assume that the following JSON represents one record:

{

"Id": "1",

"Name": "John",

"PhoneNumber": "123-555-1234"

}

You want to select name, then you can provide Record Template as

Phone number of {{Name}} is {{ PhoneNumber}}

Note:

Anything written in between {{ }} is represented as a JSON field and is case-sensitive. This would present as: Phone number of John is 123-555-1234

Empty Result Template

This indicates what should be presented if no values are returned.

Sample Response:

Method: GetTables

This Method returns the name of the table.

Parameter

Info

Method Name

Get Tables

Request Type

GetTables

This is the method that you are using

Parameters

As explained in the previous table

Result Type

ListOfRecords (Auto Selected)

It indicates that the method can return one or more records

Record Limit

Numeric value (e.g. 10)

If Method is returning larger number of records, then you can limit this result by providing this value.

Record JsonPath

Each method returns data in JSON format and to pick any specific information from the JSON, we need to specify the Record JsonPath so the platform will pick that data in consideration while displaying results.

Example: $.[*]

This option returns all the records.

Record Template

{{TableName}}

Note:

Anything written in between {{ }} is represented as a JSON field and it’s case-sensitive.

Result Template

Here are the tables. {{Records}} How else can I help you?

Here, {{Records}} represents one or more records separated by a separator.

Sample Response:

Method: GetAllItems

This method returns all records in the table

Parameters:

Parameter

Sample Value

Info

TableName

Contact

DynamoDB table name.

Parameter

Info

Method Name

GetAllItems

Request Type

GetAllItems

This is the method that you are using

Parameters

TableName: Contacts

Result Type

ListOfRecords (Auto Selected)

It indicates that the method can return one or more records

Record Limit

Numeric value (e.g. 10)

If Method is returning larger number of records, then you can limit this result by providing this value.

Record JsonPath

Each method returns data in JSON format and to pick any specific information from the JSON, we need to specify the Record JsonPath so the platform will pick that data in consideration while displaying results.

Example: $.[*]

This option returns all the records.

Record Template

Name:{{Name}}, PhoneNumber: {{PhoneNumber}}

Note:

Anything written in between {{ }} is represented as a JSON field and is case-sensitive.

Result Template

Here are the contacts available, {{Records}} How else can I help you?

Here, {{Records}} represents one or more records separated by a separator.

Sample Response:

Method: GetItem

Returns a single record.

Parameters:

Parameter

Sample Value

Info

TableName

Contact

DynamoDB table name (Case Sensitive)

PartitionKeyName

id

Name of the Partition Key for the provided table (Case Sensitive

PartitionKeyValue

1

Value for the Partition Key

Sample Response:

{ "id": "1", "PhoneNumber": "(336)222-7000", "Name": "Jack Rogers" }

Method: PutItem

Adds a record to the database.

Parameters:

Parameter

Sample Value

Info

TableName

Contact

DynamoDB table name (Case Sensitive)

PartitionKeyName

id

Name of the Partition Key (Case Sensitive)

PartitionKeyValue

5

Value for the Partition Key

ItemData

{"PhoneNumber": "(503) 421-7800","Name": "Josh Davis"}

Item data in JSON format

Sample Response:

{ "id": "5", "PhoneNumber": "(503) 421-7800", "Name": "Josh Davis" }

Method: PostItem

Adds a record to the database.

Parameters:

Parameter

Sample Value

Info

TableName

Contact

DynamoDB table name (Case Sensitive)

PartitionKeyName

id

Name of the Partition Key (Case Sensitive)

PartitionKeyValue

5

Value for the Partition Key

ItemData

{"PhoneNumber": "(503) 421-7800","Name": "Josh Davis"}

Item data in JSON format

Sample Response:

{ "id": "5", "PhoneNumber": "(503) 421-7800", "Name": "Josh Davis" }

Method: DeleteItem

Removes a record from the database.

Parameters:

Parameter

Sample Value

Info

TableName

Contact

DynamoDB table name. (Case Sensitive)

PartitionKeyName

id

Name of the Partition Key (Case Sensitive)

PartitionKeyValue

5

Value for the Partition Key

Sample Response:

{"response": "Delete Successful"}

Congratulations you’ve successfully integrated Amazon DynamoDB to an iX Hello App.

For more information on creating IAM users and assigning policies, refer to the AWS official documentation

You can also refer to the simplified iX Hello documentation at

To create an iX Hello account, follow the steps

Login to the iX Hello portal at

From here, you can now proceed to create intents, slots, inputs and then finally publish to supported publish channels. You can refer to document for further assistance to build and publish Apps. You can test your app in Alexa developer console and the expected result shall be like this

https://aws.amazon.com/premiumsupport/knowledge-center/create-access-key/
https://docs.ixHello.com/aws-iam-users
here
https://bots.ixHello.com
this
https://portal.aws.amazon.com/billing/signup#/start
https://console.aws.amazon.com/
https://aws.amazon.com/getting-started/hands-on/create-nosql-table/