{"dist":{"shasum":"12e45d71708e8f59f74aaee1ed7623863797e4f4","tarball":"https://registry.npmjs.org/@aws-sdk/client-textract-browser/-/client-textract-browser-0.1.0-preview.3.tgz","fileCount":314,"integrity":"sha512-QhsmWuro46LzyhHU+1ksn47O0Ly4/CDR7hmUiQHi1yPD0TroY4Bz7VA74yH35odtzQEDtGxqX4wdAWt+AP1YQg==","signatures":[{"sig":"MEUCIBbRvqGosF8SXSvcANlFtU/ou1/69kVZhEghyN8x9zmXAiEA8xmM50aNJdRGnrcGu7NuBkkVzCe+rmTvRwho6ynUcBE=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":206276,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJdg6XHCRA9TVsSAnZWagAAoJQP+wUvqqLgMOcWm4/Bk7Vx\nMIsIY9MwMgRJ7wDtvrpQvkuCn/aUD8MG2DrGml280Jix1lvAn4523wDPi9U5\nk/g990B4II65sg+n9N7zM/TbWa63ZYPcMrCS50GJJ1YKe2Gf8e4jMUZiyb76\nqPKs8rAz/V/2kuoOHX6v/CfaNxsU74GwJ3LyT7xNrzVbAfpwWf8MV7BKYRHj\neOWS0SaD1XUUcQ9hSqd/JoqqqyJEJqF3YKsqM+L4HaKoodODykJijfkgsyxH\nODnJGmg9nKL1epehaK8AzIiaO9l0kBUaz4FL2DaKUmWX0dagxlJsyYAqqnPo\nnRW0bqjqcSYRl+rcMWrZGWfDPEtcrLw3y/7Ux0Ty7bf84H/vVWgDj28QIpHS\no7+k3QFxWthPQk/E+5Z9pBRKhDHHVIo4lmvXQ3w6/+RS05ILROKSqq84Q9p5\nZcOpV5tkodTu52+z8nRLT6UN4xPnS/gwdc74FIeEwVrnJ+tTqYfwGb48sJuz\nL9jok7QhvhOQwo5yIxSuCzdaPdHHD5OQGB6w9QHSao6nI7EC0Pm/vAc2Q6aZ\nDbkoD9Nn8TL+xfbDEgQgJUIs5KqLtCg7jF2yzinyYuoH/r+I7/oW2/Jm0fCV\nisdNF5rZsxD/NPkXuhrGTJe1MjbvGtKoYu38OmKxZpgruwSP6Az/Qz5oqmf6\nBo3u\r\n=2njM\r\n-----END PGP SIGNATURE-----\r\n"},"main":"./index.js","name":"@aws-sdk/client-textract-browser","types":"./index.d.ts","author":{"url":"https://aws.amazon.com/javascript/","name":"AWS SDK for JavaScript Team"},"readme":"# @aws-sdk/client-textract-browser\n\n[![NPM version](https://img.shields.io/npm/v/@aws-sdk/client-textract-browser/preview.svg)](https://www.npmjs.com/package/@aws-sdk/client-textract-browser)\n[![NPM downloads](https://img.shields.io/npm/dm/@aws-sdk/client-textract-browser.svg)](https://www.npmjs.com/package/@aws-sdk/client-textract-browser)\n\n## Description\n\n<p>Amazon Textract detects and analyzes text in documents and converts it into machine-readable text. This is the API reference documentation for Amazon Textract.</p>\n\n## Installing\n\nTo install the this package using NPM, simply type the following into a terminal window:\n\n```\nnpm install @aws-sdk/client-textract-browser\n```\n\n## Getting Started\n\n### Import\n\nThe AWS SDK is modulized by clients and commands in CommonJS modules. To send a request, you only need to import the client(`TextractClient`) and the commands you need, for example `AnalyzeDocumentCommand`:\n\n```javascript\n//JavaScript\nconst {\n  TextractClient\n} = require(\"@aws-sdk/client-textract-browser/TextractClient\");\nconst {\n  AnalyzeDocumentCommand\n} = require(\"@aws-sdk/client-textract-browser/commands/AnalyzeDocumentCommand\");\n```\n\n```javascript\n//TypeScript\nimport { TextractClient } from \"@aws-sdk/client-textract-browser/TextractClient\";\nimport { AnalyzeDocumentCommand } from \"@aws-sdk/client-textract-browser/commands/AnalyzeDocumentCommand\";\n```\n\n### Usage\n\nTo send a request, you:\n\n- Initiate client with configuration (e.g. credentials, region). For more information you can refer to the [API reference][].\n- Initiate command with input parameters.\n- Call `send` operation on client with command object as input.\n- If you are using a custom http handler, you may call `destroy()` to close open connections.\n\n```javascript\nconst textract = new TextractClient({ region: \"region\" });\n//clients can be shared by different commands\nconst params = {\n  Document: {\n    /**an object specifying Document*/\n  },\n  FeatureTypes: [\n    /**a list of string*/\n  ]\n};\nconst analyzeDocumentCommand = new AnalyzeDocumentCommand(params);\ntextract\n  .send(analyzeDocumentCommand)\n  .then(data => {\n    // do something\n  })\n  .catch(error => {\n    // error handling\n  });\n```\n\nIn addition to using promises, there are 2 other ways to send a request:\n\n```javascript\n// async/await\ntry {\n  const data = await textract.send(analyzeDocumentCommand);\n  // do something\n} catch (error) {\n  // error handling\n}\n```\n\n```javascript\n// callback\ntextract.send(analyzeDocumentCommand, (err, data) => {\n  //do something\n});\n```\n\nThe SDK can also send requests using the simplified callback style from version 2 of the SDK.\n\n```javascript\nimport * as AWS from \"@aws-sdk/@aws-sdk/client-textract-browser/Textract\";\nconst textract = new AWS.Textract({ region: \"region\" });\ntextract.analyzeDocument(params, (err, data) => {\n  //do something\n});\n```\n\n### Troubleshooting\n\nWhen the service returns an exception, the error will include the exception information, as well as response metadata (e.g. request id).\n\n```javascript\ntry {\n  const data = await textract.send(analyzeDocumentCommand);\n  // do something\n} catch (error) {\n  const metadata = error.$metadata;\n  console.log(\n    `requestId: ${metadata.requestId}\ncfId: ${metadata.cfId}\nextendedRequestId: ${metadata.extendedRequestId}`\n  );\n  /*\nThe keys within exceptions are also parsed. You can access them by specifying exception names:\n    if(error.name === 'SomeServiceException') {\n        const value = error.specialKeyInException;\n    }\n*/\n}\n```\n\n## Getting Help\n\nPlease use these community resources for getting help. We use the GitHub issues for tracking bugs and feature requests and have limited bandwidth to address them.\n\n- Ask a question on [StackOverflow](https://stackoverflow.com/questions/tagged/aws-sdk-js) and tag it with `aws-sdk-js`\n- Come join the AWS JavaScript community on [gitter](https://gitter.im/aws/aws-sdk-js-v3)\n- If it turns out that you may have found a bug, please [open an issue](https://github.com/aws/aws-sdk-js-v3/issues)\n\n## Contributing\n\nThis client code is generated automatically. Any modifications will be overwritten the next time the `@aws-sdk/@aws-sdk/client-textract-browser' package is updated. To contribute to SDK you can checkout our [code generator package][].\n\n## License\n\nThis SDK is distributed under the\n[Apache License, Version 2.0](http://www.apache.org/licenses/LICENSE-2.0),\nsee LICENSE for more information.\n\n[code generator package]: https://github.com/aws/aws-sdk-js-v3/tree/master/packages/service-types-generator\n[api reference]: https://docs.aws.amazon.com/AWSJavaScriptSDK/latest/\n","license":"Apache-2.0","scripts":{"test":"exit 0","clean":"npm run remove-definitions && npm run remove-maps && npm run remove-js","pretest":"tsc","remove-js":"rimraf *.js && rimraf ./commands/*.js && rimraf ./model/*.js && rimraf ./types/*.js","smoke-test":"karma start karma.conf","remove-maps":"rimraf *.js.map && rimraf ./commands/*.js.map && rimraf ./model/*.js.map && rimraf ./types/*.js.map","prepublishOnly":"tsc","remove-definitions":"rimraf *.d.ts && rimraf ./commands/*.d.ts && rimraf ./model/*.d.ts rimraf ./types/*.d.ts","build-documentation":"npm run clean && typedoc ./","remove-documentation":"rimraf ./docs"},"_npmUser":{"name":"aws-sdk-bot","email":"aws-sdk-js@amazon.com"},"deprecated":"The package @aws-sdk/client-textract-browser has been renamed to @aws-sdk/client-textract. Please install the renamed package.","_npmVersion":"6.9.0","description":"Browser SDK for Amazon Textract","directories":{},"maintainers":[{"name":"amzn-oss","email":"osa-3p@amazon.com"},{"name":"aws-sdk-bot","email":"aws-sdk-js@amazon.com"},{"name":"trivikr-aws","email":"trivikr@amazon.com"},{"name":"zheallan","email":"zheallan@amazon.com"}],"_nodeVersion":"10.1.0","dependencies":{"tslib":"^1.8.0","@aws-sdk/types":"^0.1.0-preview.5","@aws-sdk/json-parser":"^0.1.0-preview.5","@aws-sdk/core-handler":"^0.1.0-preview.5","@aws-sdk/json-builder":"^0.1.0-preview.5","@aws-sdk/signature-v4":"^0.1.0-preview.7","@aws-sdk/config-resolver":"^0.1.0-preview.5","@aws-sdk/middleware-stack":"^0.1.0-preview.6","@aws-sdk/retry-middleware":"^0.1.0-preview.5","@aws-crypto/sha256-browser":"^0.1.0-preview.1","@aws-sdk/protocol-json-rpc":"^0.1.0-preview.6","@aws-sdk/util-utf8-browser":"^0.1.0-preview.3","@aws-sdk/fetch-http-handler":"^0.1.0-preview.5","@aws-sdk/signing-middleware":"^0.1.0-preview.7","@aws-sdk/url-parser-browser":"^0.1.0-preview.5","@aws-sdk/util-base64-browser":"^0.1.0-preview.3","@aws-sdk/middleware-serializer":"^0.1.0-preview.5","@aws-sdk/json-error-unmarshaller":"^0.1.0-preview.6","@aws-sdk/util-user-agent-browser":"^0.1.0-preview.6","@aws-sdk/stream-collector-browser":"^0.1.0-preview.5","@aws-sdk/util-body-length-browser":"^0.1.0-preview.3","@aws-sdk/middleware-content-length":"^0.1.0-preview.5","@aws-sdk/middleware-header-default":"^0.1.0-preview.5"},"_hasShrinkwrap":false,"readmeFilename":"README.md","devDependencies":{"rimraf":"^2.6.2","typedoc":"^0.14.2","typescript":"~3.4.0","@aws-sdk/client-documentation-generator":"^0.1.0-preview.3"},"_npmOperationalInternal":{"tmp":"tmp/client-textract-browser_0.1.0-preview.3_1568908742411_0.9040354109064843","host":"s3://npm-registry-packages"},"_id":"@aws-sdk/client-textract-browser@0.1.0-preview.3","version":"0.1.0-preview.3"}