Skip to content

Instantly share code, notes, and snippets.

@bottomoftheheap9000
Created January 3, 2017 19:38
Show Gist options
  • Save bottomoftheheap9000/2313449ce2fc5cfefc13c89136ed3151 to your computer and use it in GitHub Desktop.
Save bottomoftheheap9000/2313449ce2fc5cfefc13c89136ed3151 to your computer and use it in GitHub Desktop.
<html>
<head>yoyo</head>
<body>
<?php
require_once __DIR__.'/vendor/autoload.php';
use ApiAi\Client;
try {
$client = new Client('11e23882f55148e0a82a5e9dd0457e5a');
$query = $client->get('query', [
'query' => 'Hello',
]);
$response = json_decode((string) $query->getBody(), true);
} catch (\Exception $error) {
echo $error->getMessage();
}
?>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment