(window.webpackJsonp=window.webpackJsonp||[]).push([[18],{124:function(e,t,n){"use strict";n.d(t,"a",(function(){returnu})),n.d(t,"b",(function(){returnf}));varr=n(0),a=n.n(r);functiono(e,t,n){returntine?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}functioni(e,t){varn=Object.keys(e);if(Object.getOwnPropertySymbols){varr=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){returnObject.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}returnn}functionc(e){for(vart=1;t<arguments.length;t++){varn=null!=arguments[t]?arguments[t]:{};t%2?i(Object(n),!0).forEach((function(t){o(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):i(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}returne}functions(e,t){if(null==e)return{};varn,r,a=function(e,t){if(null==e)return{};varn,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(a[n]=e[n]);returna}(e,t);if(Object.getOwnPropertySymbols){varo=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}returna}varp=a.a.createContext({}),l=function(e){vart=a.a.useContext(p),n=t;returne&&(n="function"==typeofe?e(t):c(c({},t),e)),n},u=function(e){vart=l(e.components);returna.a.createElement(p.Provider,{value:t},e.children)},d={inlineCode:"code",wrapper:function(e){vart=e.children;returna.a.createElement(a.a.Fragment,{},t)}},b=a.a.forwardRef((function(e,t){varn=e.components,r=e.mdxType,o=e.originalType,i=e.parentName,p=s(e,["components","mdxType","originalType","parentName"]),u=l(n),b=r,f=u["".concat(i,".").concat(b)]||u[b]||d[b]||o;returnn?a.a.createElement(f,c(c({ref:t},p),{},{components:n})):a.a.createElement(f,c({ref:t},p))}));functionf(e,t){varn=arguments,r=t&&t.mdxType;if("string"==typeofe||r){varo=n.length,i=newArray(o);i[0]=b;varc={};for(varsint)hasOwnProperty.call(t,s)&&(c[s]=t[s]);c.originalType=e,c.mdxType="string"==typeofe?e:r,i[1]=c;for(varp=2;p<o;p++)i[p]=n[p];returna.a.createElement.apply(null,i)}returna.a.createElement.apply(null,n)}b.displayName="MDXCreateElement"},87:function(e,t,n){"use strict";n.r(t),n.d(t,"frontMatter",(function(){returni})),n.d(t,"metadata",(function(){returnc})),n.d(t,"toc",(function(){returns})),n.d(t,"default",(function(){returnl}));varr=n(3),a=n(7),o=(n(0),n(124)),i={id:"error_handling",title:"Error Handling"},c={unversionedId:"error_handling",id:"error_handling",isDocsHomePage:!1,title:"Error Handling",description:"API calls can fail when input data is malformed or the server detects issues with the request. As an example, the following request obviously fails:",source:"@site/docs/error_handling.md",slug:"/error_handling",permalink:"/SpotifyAPI-NET/docs/error_handling",editUrl:"https://github.com/JohnnyCrazy/SpotifyAPI-NET/edit/master/SpotifyAPI.Docs/docs/error_handling.md",version:"current",lastUpdatedBy:"dependabot[bot]",lastUpdatedAt:1620577961,formattedLastUpdatedAt:"5/9/2021",sidebar:"docs",previous:{title:"Getting Started",permalink:"/SpotifyAPI-NET/docs/getting_started"},next:{title:"Configuration",permalink:"/SpotifyAPI-NET/docs/configuration"}},s=[{value:"APIException",id:"apiexception",children:[]},{value:"APIUnauthorizedException",id:"apiunauthorizedexception",children:[]},{value:"APITooManyRequestsException",id:"apitoomanyrequestsexception",children:[]}],p={toc:s};functionl(e){vart=e.components,n=Object(a.a)(e,["components"]);returnObject(o.b)("wrapper",Object(r.a)({},p,n,{components:t,mdxType:"MDXLayout"}),Object(o.b)("p",null,"API calls can fail when input data is malformed or the server detects issues with the request. As an example, the following request obviously fails:"),Object(o.b)("pre",null,Object(o.b)("code",{parentName:"pre",className:"language-csharp"},'var track = await spotify.Tracks.Get("NotExistingTrackId");\nConsole.WriteLine(track.Name);\n')),Object(o.b)("p",null,"When a request fails, an ",Object(o.b)("i