"use strict";(self.webpackChunkspotify_api_docs=self.webpackChunkspotify_api_docs||[]).push([[5935],{3905:function(e,t,n){n.d(t,{Zo:function(){returnp},kt:function(){returnf}});varr=n(7294);functiono(e,t,n){returntine?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}functiona(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}functioni(e){for(vart=1;t<arguments.length;t++){varn=null!=arguments[t]?arguments[t]:{};t%2?a(Object(n),!0).forEach((function(t){o(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):a(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}returne}functionl(e,t){if(null==e)return{};varn,r,o=function(e,t){if(null==e)return{};varn,r,o={},a=Object.keys(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||(o[n]=e[n]);returno}(e,t);if(Object.getOwnPropertySymbols){vara=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}returno}vars=r.createContext({}),c=function(e){vart=r.useContext(s),n=t;returne&&(n="function"==typeofe?e(t):i(i({},t),e)),n},p=function(e){vart=c(e.components);returnr.createElement(s.Provider,{value:t},e.children)},u={inlineCode:"code",wrapper:function(e){vart=e.children;returnr.createElement(r.Fragment,{},t)}},d=r.forwardRef((function(e,t){varn=e.components,o=e.mdxType,a=e.originalType,s=e.parentName,p=l(e,["components","mdxType","originalType","parentName"]),d=c(n),f=o,h=d["".concat(s,".").concat(f)]||d[f]||u[f]||a;returnn?r.createElement(h,i(i({ref:t},p),{},{components:n})):r.createElement(h,i({ref:t},p))}));functionf(e,t){varn=arguments,o=t&&t.mdxType;if("string"==typeofe||o){vara=n.length,i=newArray(a);i[0]=d;varl={};for(varsint)hasOwnProperty.call(t,s)&&(l[s]=t[s]);l.originalType=e,l.mdxType="string"==typeofe?e:o,i[1]=l;for(varc=2;c<a;c++)i[c]=n[c];returnr.createElement.apply(null,i)}returnr.createElement.apply(null,n)}d.displayName="MDXCreateElement"},9294:function(e,t,n){n.r(t),n.d(t,{assets:function(){returnp},contentTitle:function(){returns},default:function(){returnf},frontMatter:function(){returnl},metadata:function(){returnc},toc:function(){returnu}});varr=n(7462),o=n(3366),a=(n(7294),n(3905)),i=["components"],l={id:"pkce",title:"PKCE"},s=void0,c={unversionedId:"pkce",id:"pkce",title:"PKCE",description:"The authorization code flow with PKCE is the best option for mobile and desktop applications where it is unsafe to store your client secret. It provides your app with an access token that can be refreshed. For further information about this flow, see IETF RFC-7636.",source:"@site/docs/pkce.md",sourceDirName:".",slug:"/pkce",permalink:"/SpotifyAPI-NET/docs/pkce",draft:!1,editUrl:"https://github.com/JohnnyCrazy/SpotifyAPI-NET/edit/master/SpotifyAPI.Docs/docs/pkce.md",tags:[],version:"current",lastUpdatedBy:"Jonas Dellinger",lastUpdatedAt:1669550870,formattedLastUpdatedAt:"Nov 27, 2022",frontMatter:{id:"pkce",title:"PKCE"},sidebar:"docs",previous:{title:"Authorization Code",permalink:"/SpotifyAPI-NET/docs/authorization_code"},next:{title:"Token Swap",permalink:"/SpotifyAPI-NET/docs/token_swap"}},p={},u=[{value:"Generating Challenge & Verifier",id:"generating-challenge--verifier",level:2},{value:"Generating Login URI",id:"generating-login-uri",level:2}],d={toc:u};functionf(e){vart=e.components,n=(0,o.Z)(e,i);return(0,a.kt)("wrapper",(0,r.Z)({},d,n,{components:t,mdxType:"MDXLayout"}),(0,a.kt)("blockquote",null,(0,a.kt)("p",{parentName:"blockquote"},"The authorization code flow with PKCE is the best option for mobile and desktop applications where it is unsafe to store your client secret. It provides your app with an access token that can be refreshed. For further information about this flow, see ",(0,a.kt)("a",{parentName:"p",href:"https://tools.i