{"kind":"symbol","abstract":[{"text":"Get details about a OAuth request token.","type":"text"}],"primaryContentSections":[{"declarations":[{"tokens":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"getRequestToken"},{"kind":"text","text":"("},{"kind":"externalParam","text":"_"},{"kind":"text","text":" "},{"kind":"internalParam","text":"input"},{"kind":"text","text":": "},{"kind":"typeIdentifier","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations","preciseIdentifier":"s:14DiscogsService10OperationsO","text":"Operations"},{"kind":"text","text":"."},{"kind":"typeIdentifier","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/GetRequestToken","preciseIdentifier":"s:14DiscogsService10OperationsO15GetRequestTokenO","text":"GetRequestToken"},{"kind":"text","text":"."},{"kind":"typeIdentifier","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/GetRequestToken\/Input","preciseIdentifier":"s:14DiscogsService10OperationsO15GetRequestTokenO5InputV","text":"Input"},{"kind":"text","text":") "},{"kind":"keyword","text":"async"},{"kind":"text","text":" "},{"kind":"keyword","text":"throws"},{"kind":"text","text":" -> "},{"kind":"typeIdentifier","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations","preciseIdentifier":"s:14DiscogsService10OperationsO","text":"Operations"},{"kind":"text","text":"."},{"kind":"typeIdentifier","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/GetRequestToken","preciseIdentifier":"s:14DiscogsService10OperationsO15GetRequestTokenO","text":"GetRequestToken"},{"kind":"text","text":"."},{"kind":"typeIdentifier","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/GetRequestToken\/Output","preciseIdentifier":"s:14DiscogsService10OperationsO15GetRequestTokenO6OutputO","text":"Output"}],"languages":["swift"],"platforms":["macOS"]}],"kind":"declarations"},{"content":[{"level":2,"text":"Discussion","anchor":"discussion","type":"heading"},{"inlineContent":[{"type":"text","text":"Retrieve a request token to initialize an "},{"type":"emphasis","inlineContent":[{"type":"text","text":"OAuth"}]},{"type":"text","text":" authentication process."}],"type":"paragraph"},{"inlineContent":[{"type":"text","text":"This endpoint represents the "},{"type":"reference","identifier":"https:\/\/www.discogs.com\/developers#header-2.-send-a-get-request-to-the-discogs-request-token-url","isActive":true},{"type":"text","text":", thus it requires to configure an "},{"type":"emphasis","inlineContent":[{"type":"text","text":"Authorization"}]},{"type":"text","text":" header to have a value like this:"}],"type":"paragraph"},{"code":["OAuth oauth_consumer_key=\"your_consumer_key\", oauth_nonce=\"random_string_or_timestamp\", oauth_signature=\"your_consumer_secret&\", oauth_signature_method=\"PLAINTEXT\", oauth_timestamp=\"current_timestamp\", oauth_callback=\"your_callback\""],"syntax":null,"type":"codeListing"},{"inlineContent":[{"type":"text","text":"For further details about this process, please refer to the "},{"type":"reference","identifier":"https:\/\/www.discogs.com\/developers#page:authentication,header:authentication-oauth-flow","isActive":true},{"type":"text","text":" section in the "},{"type":"reference","identifier":"https:\/\/www.discogs.com\/developers#page:authentication","isActive":true},{"type":"text","text":" documentation."}],"type":"paragraph"},{"name":"Remark","content":[{"type":"paragraph","inlineContent":[{"type":"text","text":"HTTP "},{"type":"codeVoice","code":"GET \/oauth\/request_token"},{"type":"text","text":"."}]}],"style":"note","type":"aside"},{"name":"Remark","content":[{"type":"paragraph","inlineContent":[{"type":"text","text":"Generated from "},{"type":"codeVoice","code":"#\/paths\/\/oauth\/request_token\/get(getRequestToken)"},{"type":"text","text":"."}]}],"style":"note","type":"aside"}],"kind":"content"}],"hierarchy":{"paths":[["doc:\/\/DiscogsService\/documentation\/DiscogsService","doc:\/\/DiscogsService\/documentation\/DiscogsService\/Client"]]},"sections":[],"metadata":{"symbolKind":"method","title":"getRequestToken(_:)","externalID":"s:14DiscogsService6ClientV15getRequestTokenyAA10OperationsO03GeteF0O6OutputOAH5InputVYaKF","roleHeading":"Instance Method","fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"getRequestToken"},{"kind":"text","text":"("},{"kind":"typeIdentifier","preciseIdentifier":"s:14DiscogsService10OperationsO","text":"Operations"},{"kind":"text","text":"."},{"kind":"typeIdentifier","preciseIdentifier":"s:14DiscogsService10OperationsO15GetRequestTokenO","text":"GetRequestToken"},{"kind":"text","text":"."},{"kind":"typeIdentifier","preciseIdentifier":"s:14DiscogsService10OperationsO15GetRequestTokenO5InputV","text":"Input"},{"kind":"text","text":") "},{"kind":"keyword","text":"async"},{"kind":"text","text":" "},{"kind":"keyword","text":"throws"},{"kind":"text","text":" -> "},{"kind":"typeIdentifier","preciseIdentifier":"s:14DiscogsService10OperationsO","text":"Operations"},{"kind":"text","text":"."},{"kind":"typeIdentifier","preciseIdentifier":"s:14DiscogsService10OperationsO15GetRequestTokenO","text":"GetRequestToken"},{"kind":"text","text":"."},{"kind":"typeIdentifier","preciseIdentifier":"s:14DiscogsService10OperationsO15GetRequestTokenO6OutputO","text":"Output"}],"modules":[{"name":"DiscogsService"}],"role":"symbol"},"identifier":{"url":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Client\/getRequestToken(_:)","interfaceLanguage":"swift"},"schemaVersion":{"major":0,"minor":3,"patch":0},"seeAlsoSections":[{"generated":true,"anchor":"Authentication-endpoints","title":"Authentication endpoints","identifiers":["doc:\/\/DiscogsService\/documentation\/DiscogsService\/Client\/postAccessToken(_:)","doc:\/\/DiscogsService\/documentation\/DiscogsService\/Client\/getUserIdentity(_:)"]}],"variants":[{"paths":["\/documentation\/discogsservice\/client\/getrequesttoken(_:)"],"traits":[{"interfaceLanguage":"swift"}]}],"references":{"https://www.discogs.com/developers#page:authentication":{"titleInlineContent":[{"text":"Discogs API authentication","type":"text"}],"type":"link","url":"https:\/\/www.discogs.com\/developers#page:authentication","title":"Discogs API authentication","identifier":"https:\/\/www.discogs.com\/developers#page:authentication"},"https://www.discogs.com/developers#header-2.-send-a-get-request-to-the-discogs-request-token-url":{"titleInlineContent":[{"text":"2nd step of the OAuth flow process","type":"text"}],"type":"link","url":"https:\/\/www.discogs.com\/developers#header-2.-send-a-get-request-to-the-discogs-request-token-url","title":"2nd step of the OAuth flow process","identifier":"https:\/\/www.discogs.com\/developers#header-2.-send-a-get-request-to-the-discogs-request-token-url"},"doc://DiscogsService/documentation/DiscogsService/Operations/GetRequestToken":{"abstract":[{"type":"text","text":"Get details about a OAuth request token."}],"kind":"symbol","type":"topic","title":"Operations.GetRequestToken","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/GetRequestToken","url":"\/documentation\/discogsservice\/operations\/getrequesttoken","fragments":[{"kind":"keyword","text":"enum"},{"kind":"text","text":" "},{"kind":"identifier","text":"GetRequestToken"}],"role":"symbol","navigatorTitle":[{"kind":"identifier","text":"GetRequestToken"}]},"doc://DiscogsService/documentation/DiscogsService":{"title":"DiscogsService","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService","url":"\/documentation\/discogsservice","abstract":[],"role":"collection","kind":"symbol","type":"topic"},"doc://DiscogsService/documentation/DiscogsService/Operations/GetRequestToken/Output":{"kind":"symbol","fragments":[{"kind":"keyword","text":"enum"},{"text":" ","kind":"text"},{"kind":"identifier","text":"Output"}],"abstract":[],"identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/GetRequestToken\/Output","title":"Operations.GetRequestToken.Output","url":"\/documentation\/discogsservice\/operations\/getrequesttoken\/output","role":"symbol","navigatorTitle":[{"text":"Output","kind":"identifier"}],"type":"topic"},"doc://DiscogsService/documentation/DiscogsService/Client/postAccessToken(_:)":{"type":"topic","role":"symbol","fragments":[{"text":"func","kind":"keyword"},{"text":" ","kind":"text"},{"text":"postAccessToken","kind":"identifier"},{"text":"(","kind":"text"},{"text":"Operations","kind":"typeIdentifier","preciseIdentifier":"s:14DiscogsService10OperationsO"},{"text":".","kind":"text"},{"text":"PostAccessToken","kind":"typeIdentifier","preciseIdentifier":"s:14DiscogsService10OperationsO15PostAccessTokenO"},{"text":".","kind":"text"},{"text":"Input","kind":"typeIdentifier","preciseIdentifier":"s:14DiscogsService10OperationsO15PostAccessTokenO5InputV"},{"text":") ","kind":"text"},{"text":"async","kind":"keyword"},{"text":" ","kind":"text"},{"text":"throws","kind":"keyword"},{"text":" -> ","kind":"text"},{"text":"Operations","kind":"typeIdentifier","preciseIdentifier":"s:14DiscogsService10OperationsO"},{"text":".","kind":"text"},{"text":"PostAccessToken","kind":"typeIdentifier","preciseIdentifier":"s:14DiscogsService10OperationsO15PostAccessTokenO"},{"text":".","kind":"text"},{"text":"Output","kind":"typeIdentifier","preciseIdentifier":"s:14DiscogsService10OperationsO15PostAccessTokenO6OutputO"}],"title":"postAccessToken(_:)","url":"\/documentation\/discogsservice\/client\/postaccesstoken(_:)","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Client\/postAccessToken(_:)","abstract":[{"type":"text","text":"Provide required credentials data to obtain an access token."}],"kind":"symbol"},"doc://DiscogsService/documentation/DiscogsService/Client/getRequestToken(_:)":{"type":"topic","role":"symbol","fragments":[{"text":"func","kind":"keyword"},{"text":" ","kind":"text"},{"text":"getRequestToken","kind":"identifier"},{"text":"(","kind":"text"},{"text":"Operations","kind":"typeIdentifier","preciseIdentifier":"s:14DiscogsService10OperationsO"},{"text":".","kind":"text"},{"text":"GetRequestToken","kind":"typeIdentifier","preciseIdentifier":"s:14DiscogsService10OperationsO15GetRequestTokenO"},{"text":".","kind":"text"},{"text":"Input","kind":"typeIdentifier","preciseIdentifier":"s:14DiscogsService10OperationsO15GetRequestTokenO5InputV"},{"text":") ","kind":"text"},{"text":"async","kind":"keyword"},{"text":" ","kind":"text"},{"text":"throws","kind":"keyword"},{"text":" -> ","kind":"text"},{"text":"Operations","kind":"typeIdentifier","preciseIdentifier":"s:14DiscogsService10OperationsO"},{"text":".","kind":"text"},{"text":"GetRequestToken","kind":"typeIdentifier","preciseIdentifier":"s:14DiscogsService10OperationsO15GetRequestTokenO"},{"text":".","kind":"text"},{"text":"Output","kind":"typeIdentifier","preciseIdentifier":"s:14DiscogsService10OperationsO15GetRequestTokenO6OutputO"}],"title":"getRequestToken(_:)","url":"\/documentation\/discogsservice\/client\/getrequesttoken(_:)","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Client\/getRequestToken(_:)","abstract":[{"type":"text","text":"Get details about a OAuth request token."}],"kind":"symbol"},"doc://DiscogsService/documentation/DiscogsService/Client/getUserIdentity(_:)":{"type":"topic","role":"symbol","fragments":[{"text":"func","kind":"keyword"},{"text":" ","kind":"text"},{"text":"getUserIdentity","kind":"identifier"},{"text":"(","kind":"text"},{"text":"Operations","kind":"typeIdentifier","preciseIdentifier":"s:14DiscogsService10OperationsO"},{"text":".","kind":"text"},{"text":"GetUserIdentity","kind":"typeIdentifier","preciseIdentifier":"s:14DiscogsService10OperationsO15GetUserIdentityO"},{"text":".","kind":"text"},{"text":"Input","kind":"typeIdentifier","preciseIdentifier":"s:14DiscogsService10OperationsO15GetUserIdentityO5InputV"},{"text":") ","kind":"text"},{"text":"async","kind":"keyword"},{"text":" ","kind":"text"},{"text":"throws","kind":"keyword"},{"text":" -> ","kind":"text"},{"text":"Operations","kind":"typeIdentifier","preciseIdentifier":"s:14DiscogsService10OperationsO"},{"text":".","kind":"text"},{"text":"GetUserIdentity","kind":"typeIdentifier","preciseIdentifier":"s:14DiscogsService10OperationsO15GetUserIdentityO"},{"text":".","kind":"text"},{"text":"Output","kind":"typeIdentifier","preciseIdentifier":"s:14DiscogsService10OperationsO15GetUserIdentityO6OutputO"}],"title":"getUserIdentity(_:)","url":"\/documentation\/discogsservice\/client\/getuseridentity(_:)","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Client\/getUserIdentity(_:)","abstract":[{"type":"text","text":"Get information about an authenticated user."}],"kind":"symbol"},"doc://DiscogsService/documentation/DiscogsService/Client":{"kind":"symbol","fragments":[{"text":"struct","kind":"keyword"},{"text":" ","kind":"text"},{"text":"Client","kind":"identifier"}],"abstract":[{"text":"The Discogs API v2.0 is a RESTful interface to Discogs data. You can access JSON-formatted information about Database objects such as ","type":"text"},{"type":"emphasis","inlineContent":[{"type":"text","text":"Artists"}]},{"text":", ","type":"text"},{"type":"emphasis","inlineContent":[{"type":"text","text":"Releases"}]},{"text":", and ","type":"text"},{"type":"emphasis","inlineContent":[{"type":"text","text":"Labels"}]},{"text":". Your application can also manage ","type":"text"},{"type":"emphasis","inlineContent":[{"type":"text","text":"User Collections"}]},{"text":" and ","type":"text"},{"type":"emphasis","inlineContent":[{"type":"text","text":"Wantlists"}]},{"text":", create ","type":"text"},{"type":"emphasis","inlineContent":[{"type":"text","text":"Marketplace"}]},{"text":" listings, and more.","type":"text"}],"identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Client","title":"Client","url":"\/documentation\/discogsservice\/client","role":"symbol","navigatorTitle":[{"text":"Client","kind":"identifier"}],"type":"topic"},"doc://DiscogsService/documentation/DiscogsService/Operations":{"type":"topic","role":"symbol","fragments":[{"kind":"keyword","text":"enum"},{"kind":"text","text":" "},{"text":"Operations","kind":"identifier"}],"navigatorTitle":[{"kind":"identifier","text":"Operations"}],"title":"Operations","url":"\/documentation\/discogsservice\/operations","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations","abstract":[{"type":"text","text":"API operations, with input and output types, generated from "},{"type":"codeVoice","code":"#\/paths"},{"text":" in the OpenAPI document.","type":"text"}],"kind":"symbol"},"https://www.discogs.com/developers#page:authentication,header:authentication-oauth-flow":{"titleInlineContent":[{"text":"OAuth flow","type":"text"}],"type":"link","url":"https:\/\/www.discogs.com\/developers#page:authentication,header:authentication-oauth-flow","title":"OAuth flow","identifier":"https:\/\/www.discogs.com\/developers#page:authentication,header:authentication-oauth-flow"},"doc://DiscogsService/documentation/DiscogsService/Operations/GetRequestToken/Input":{"kind":"symbol","fragments":[{"text":"struct","kind":"keyword"},{"text":" ","kind":"text"},{"kind":"identifier","text":"Input"}],"abstract":[],"identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/GetRequestToken\/Input","title":"Operations.GetRequestToken.Input","url":"\/documentation\/discogsservice\/operations\/getrequesttoken\/input","role":"symbol","navigatorTitle":[{"kind":"identifier","text":"Input"}],"type":"topic"}}}