Files
discogs-service/docs/data/documentation/discogsservice/apiprotocol/getrequesttoken(_:).json
T

1 line
20 KiB
JSON
Raw Normal View History

{"kind":"symbol","abstract":[{"type":"text","text":"Get details about a OAuth request token."}],"primaryContentSections":[{"declarations":[{"tokens":[{"text":"func","kind":"keyword"},{"text":" ","kind":"text"},{"text":"getRequestToken","kind":"identifier"},{"text":"(","kind":"text"},{"text":"_","kind":"externalParam"},{"text":" ","kind":"text"},{"text":"input","kind":"internalParam"},{"text":": ","kind":"text"},{"preciseIdentifier":"s:14DiscogsService10OperationsO","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations","text":"Operations","kind":"typeIdentifier"},{"text":".","kind":"text"},{"preciseIdentifier":"s:14DiscogsService10OperationsO15GetRequestTokenO","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/GetRequestToken","text":"GetRequestToken","kind":"typeIdentifier"},{"text":".","kind":"text"},{"preciseIdentifier":"s:14DiscogsService10OperationsO15GetRequestTokenO5InputV","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/GetRequestToken\/Input","text":"Input","kind":"typeIdentifier"},{"text":") ","kind":"text"},{"text":"async","kind":"keyword"},{"text":" ","kind":"text"},{"text":"throws","kind":"keyword"},{"text":" -> ","kind":"text"},{"preciseIdentifier":"s:14DiscogsService10OperationsO","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations","text":"Operations","kind":"typeIdentifier"},{"text":".","kind":"text"},{"preciseIdentifier":"s:14DiscogsService10OperationsO15GetRequestTokenO","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/GetRequestToken","text":"GetRequestToken","kind":"typeIdentifier"},{"text":".","kind":"text"},{"preciseIdentifier":"s:14DiscogsService10OperationsO15GetRequestTokenO6OutputO","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/GetRequestToken\/Output","text":"Output","kind":"typeIdentifier"}],"platforms":["macOS"],"languages":["swift"]}],"kind":"declarations"},{"kind":"content","content":[{"type":"heading","anchor":"discussion","level":2,"text":"Discussion"},{"inlineContent":[{"type":"text","text":"Retrieve a request token to initialize an "},{"inlineContent":[{"type":"text","text":"OAuth"}],"type":"emphasis"},{"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 "},{"inlineContent":[{"type":"text","text":"Authorization"}],"type":"emphasis"},{"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\""],"type":"codeListing","syntax":null},{"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","type":"aside","content":[{"inlineContent":[{"type":"text","text":"HTTP "},{"type":"codeVoice","code":"GET \/oauth\/request_token"},{"type":"text","text":"."}],"type":"paragraph"}],"style":"note"},{"name":"Remark","type":"aside","content":[{"inlineContent":[{"type":"text","text":"Generated from "},{"type":"codeVoice","code":"#\/paths\/\/oauth\/request_token\/get(getRequestToken)"},{"type":"text","text":"."}],"type":"paragraph"}],"style":"note"}]}],"metadata":{"symbolKind":"method","title":"getRequestToken(_:)","externalID":"s:14DiscogsService11