{"componentChunkName":"component---src-templates-docs-js","path":"/shorturl/url_shortener/response","result":{"data":{"site":{"siteMetadata":{"title":"broadcaster","docsLocation":"https://github.com","docsLocationType":"github","editable":false}},"mdx":{"fields":{"id":"188e286e-6fa0-50ef-b8d5-aadeeeb6cbac","title":"Response","slug":"/shorturl/url_shortener/response"},"body":"function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }\n\nfunction _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }\n\nfunction _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }\n\n/* @jsx mdx */\nvar _frontmatter = {\n  \"title\": \"Response\",\n  \"order\": 2\n};\nvar layoutProps = {\n  _frontmatter: _frontmatter\n};\nvar MDXLayout = \"wrapper\";\nreturn function MDXContent(_ref) {\n  var components = _ref.components,\n      props = _objectWithoutProperties(_ref, [\"components\"]);\n\n  return mdx(MDXLayout, _extends({}, layoutProps, props, {\n    components: components,\n    mdxType: \"MDXLayout\"\n  }), mdx(\"p\", null, \"The response returned by the service is a JSON string that varies according to the response type.\"), mdx(\"section\", {\n    \"id\": \"successfulresponseexample\"\n  }, mdx(\"h3\", {\n    parentName: \"section\"\n  }, \"Successful response example\"), mdx(\"pre\", {\n    parentName: \"section\"\n  }, mdx(\"code\", {\n    parentName: \"pre\",\n    \"className\": \"language-json\"\n  }, \"{\\n    \\\"mappings\\\": [\\n        {\\n            \\\"name\\\": \\\" Google Short URL\\\",\\n            \\\"originalURL\\\": \\\"http://google.com\\\",\\n            \\\"shortURL\\\": \\\"http://bcm.com/2g3L\\\",\\n            \\\"shortenedPrev\\\": false\\n        },\\n        {\\n            \\\"name\\\": \\\"1-201905311532397\\\",\\n            \\\"originalURL\\\": \\\"https://mail.google.com\\\",\\n            \\\"shortURL\\\": \\\"http://bcm.com/2g3M\\\",\\n            \\\"shortenedPrev\\\": true\\n        }\\n    ]\\n}\\n\")), mdx(\"br\", null), mdx(\"table\", {\n    parentName: \"section\"\n  }, mdx(\"thead\", {\n    parentName: \"table\"\n  }, mdx(\"tr\", {\n    parentName: \"thead\"\n  }, mdx(\"th\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"Name\"), mdx(\"th\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"Description\"))), mdx(\"tbody\", {\n    parentName: \"table\"\n  }, mdx(\"tr\", {\n    parentName: \"tbody\"\n  }, mdx(\"td\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"mappings\"), mdx(\"td\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"Array containing the result for each requested URL\")), mdx(\"tr\", {\n    parentName: \"tbody\"\n  }, mdx(\"td\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"name\"), mdx(\"td\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"Name assigned to the URL; if none was provided, it is generated automatically.\")), mdx(\"tr\", {\n    parentName: \"tbody\"\n  }, mdx(\"td\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"originalURL\"), mdx(\"td\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"Original URL.\")), mdx(\"tr\", {\n    parentName: \"tbody\"\n  }, mdx(\"td\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"shortURL\"), mdx(\"td\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"Shortened URL.\")), mdx(\"tr\", {\n    parentName: \"tbody\"\n  }, mdx(\"td\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"shortenedPrev\"), mdx(\"td\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"Flag indicating whether the URL was shortened for the first time or had already been requested.\"))))), mdx(\"section\", {\n    \"id\": \"errorresponseexample\"\n  }, mdx(\"h3\", {\n    parentName: \"section\"\n  }, \"Error response example\"), mdx(\"p\", {\n    parentName: \"section\"\n  }, \"When there is a problem processing the request, the JSON string changes; the string you will receive is shown below. \"), mdx(\"pre\", {\n    parentName: \"section\"\n  }, mdx(\"code\", {\n    parentName: \"pre\",\n    \"className\": \"language-json\"\n  }, \"{\\n    \\\"error\\\": {\\n        \\\"code\\\": \\\"ERROR_INVALID_PARAMETER\\\",\\n        \\\"message\\\": \\\"Bad arguments\\\",\\n        \\\"status\\\": 400\\n    }\\n}\\n\")), mdx(\"br\", null), mdx(\"table\", {\n    parentName: \"section\"\n  }, mdx(\"thead\", {\n    parentName: \"table\"\n  }, mdx(\"tr\", {\n    parentName: \"thead\"\n  }, mdx(\"th\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"Name\"), mdx(\"th\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"Description\"))), mdx(\"tbody\", {\n    parentName: \"table\"\n  }, mdx(\"tr\", {\n    parentName: \"tbody\"\n  }, mdx(\"td\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"code\"), mdx(\"td\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"Result code; its value indicates the type of error that occurred.\")), mdx(\"tr\", {\n    parentName: \"tbody\"\n  }, mdx(\"td\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"message\"), mdx(\"td\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"Describes the type of error that occurred.\")), mdx(\"tr\", {\n    parentName: \"tbody\"\n  }, mdx(\"td\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"status\"), mdx(\"td\", {\n    parentName: \"tr\",\n    \"align\": null\n  }, \"Identifies the error that occurred with a numeric value.\"))))));\n}\n;\nMDXContent.isMDXComponent = true;","tableOfContents":{"items":[{"url":"#successful-response-example","title":"Successful response example"},{"url":"#error-response-example","title":"Error response example"}]},"timeToRead":1,"parent":{"__typename":"File","relativePath":"shorturl/url_shortener/response.md","fields":{"gitLogLatestAuthorName":"Irais Aguirre","gitLogLatestAuthorEmail":"irais.aguirre@conceptomovil.com","gitLogLatestDate":"7 days ago"}},"frontmatter":{"metaTitle":null,"showMetadata":null,"editable":null,"showPreviousNext":null,"showToc":null}},"gitBranch":{"name":"20211019-2FACTOR_AUTH"},"gitCommit":{"hash":"9713e1925aeb8cad930f91b6bf05d0b5937b2bb5","date":"2026-11-13 06:39"}},"pageContext":{"id":"188e286e-6fa0-50ef-b8d5-aadeeeb6cbac"}},"staticQueryHashes":["12478684","12478684","2882937274","2882937274","353167761","353167761"]}