Skip to content

Instantly share code, notes, and snippets.

Created July 16, 2019 15:37
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save mgwedd/fae65225dcb3c738c5a85fd2dd0f9aed to your computer and use it in GitHub Desktop.
// Initialising AWS IoT And IoT DataManager
AWSIoT.register(with: configuration!, forKey: "kAWSIoT") // Same configuration var as above
let iotEndPoint = AWSEndpoint(urlString: "wss://") // Access from AWS IoT Core --> Settings
let iotDataConfiguration = AWSServiceConfiguration(region: you-region-here, // Use AWS typedef .Region
endpoint: iotEndPoint,
credentialsProvider: credentials) // credentials is the same var as created above
AWSIoTDataManager.register(with: iotDataConfiguration!, forKey: "kDataManager")
// Access the AWSDataManager instance as follows:
let dataManager = AWSIoTDataManager(forKey: "kDataManager")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment