bfc9e67d38
This PR contains the work done to implement the `AuthMiddleware` middleware, to authenticate the requests sent to the backend service, based on [their specifications](https://www.discogs.com/developers/#page:authentication). In addition, some documentation has been added/updated and some boilerplate source code has been removed from the project. Reviewed-on: #3 Co-authored-by: Javier Cicchelli <javier@rock-n-code.com> Co-committed-by: Javier Cicchelli <javier@rock-n-code.com>
1 line
16 KiB
JSON
1 line
16 KiB
JSON
{"kind":"symbol","abstract":[{"text":"Get information about a release","type":"text"}],"identifier":{"url":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/APIProtocol\/getRelease(path:query:headers:)","interfaceLanguage":"swift"},"variants":[{"paths":["\/documentation\/discogsservice\/apiprotocol\/getrelease(path:query:headers:)"],"traits":[{"interfaceLanguage":"swift"}]}],"sections":[],"metadata":{"title":"getRelease(path:query:headers:)","roleHeading":"Instance Method","fragments":[{"kind":"keyword","text":"func"},{"text":" ","kind":"text"},{"kind":"identifier","text":"getRelease"},{"kind":"text","text":"("},{"kind":"externalParam","text":"path"},{"kind":"text","text":": "},{"text":"Operations","kind":"typeIdentifier","preciseIdentifier":"s:14DiscogsService10OperationsO"},{"kind":"text","text":"."},{"text":"getRelease","kind":"typeIdentifier","preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO"},{"text":".","kind":"text"},{"text":"Input","preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO5InputV","kind":"typeIdentifier"},{"text":".","kind":"text"},{"text":"Path","preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO5InputV4PathV","kind":"typeIdentifier"},{"text":", ","kind":"text"},{"text":"query","kind":"externalParam"},{"kind":"text","text":": "},{"text":"Operations","preciseIdentifier":"s:14DiscogsService10OperationsO","kind":"typeIdentifier"},{"text":".","kind":"text"},{"kind":"typeIdentifier","text":"getRelease","preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO"},{"kind":"text","text":"."},{"kind":"typeIdentifier","text":"Input","preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO5InputV"},{"kind":"text","text":"."},{"kind":"typeIdentifier","text":"Query","preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO5InputV5QueryV"},{"kind":"text","text":", "},{"text":"headers","kind":"externalParam"},{"text":": ","kind":"text"},{"text":"Operations","preciseIdentifier":"s:14DiscogsService10OperationsO","kind":"typeIdentifier"},{"kind":"text","text":"."},{"text":"getRelease","preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO","kind":"typeIdentifier"},{"kind":"text","text":"."},{"preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO5InputV","kind":"typeIdentifier","text":"Input"},{"kind":"text","text":"."},{"preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO5InputV7HeadersV","kind":"typeIdentifier","text":"Headers"},{"text":") ","kind":"text"},{"kind":"keyword","text":"async"},{"kind":"text","text":" "},{"kind":"keyword","text":"throws"},{"text":" -> ","kind":"text"},{"kind":"typeIdentifier","text":"Operations","preciseIdentifier":"s:14DiscogsService10OperationsO"},{"text":".","kind":"text"},{"kind":"typeIdentifier","text":"getRelease","preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO"},{"text":".","kind":"text"},{"kind":"typeIdentifier","text":"Output","preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO6OutputO"}],"externalID":"s:14DiscogsService11APIProtocolPAAE10getRelease4path5query7headersAA10OperationsOADO6OutputOAJ5InputV4PathV_AN5QueryVAN7HeadersVtYaKF","extendedModule":"DiscogsService","role":"symbol","symbolKind":"method","modules":[{"name":"DiscogsService"}]},"hierarchy":{"paths":[["doc:\/\/DiscogsService\/documentation\/DiscogsService","doc:\/\/DiscogsService\/documentation\/DiscogsService\/APIProtocol"]]},"schemaVersion":{"patch":0,"minor":3,"major":0},"primaryContentSections":[{"kind":"declarations","declarations":[{"languages":["swift"],"platforms":["macOS"],"tokens":[{"kind":"keyword","text":"func"},{"text":" ","kind":"text"},{"kind":"identifier","text":"getRelease"},{"text":"(","kind":"text"},{"kind":"externalParam","text":"path"},{"text":": ","kind":"text"},{"identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations","text":"Operations","preciseIdentifier":"s:14DiscogsService10OperationsO","kind":"typeIdentifier"},{"kind":"text","text":"."},{"identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getRelease","text":"getRelease","preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO","kind":"typeIdentifier"},{"kind":"text","text":"."},{"preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO5InputV","kind":"typeIdentifier","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getRelease\/Input","text":"Input"},{"kind":"text","text":"."},{"text":"Path","kind":"typeIdentifier","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getRelease\/Input\/Path-swift.struct","preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO5InputV4PathV"},{"text":", ","kind":"text"},{"text":"query","kind":"externalParam"},{"kind":"text","text":": "},{"preciseIdentifier":"s:14DiscogsService10OperationsO","kind":"typeIdentifier","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations","text":"Operations"},{"text":".","kind":"text"},{"text":"getRelease","kind":"typeIdentifier","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getRelease","preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO"},{"text":".","kind":"text"},{"text":"Input","kind":"typeIdentifier","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getRelease\/Input","preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO5InputV"},{"text":".","kind":"text"},{"text":"Query","kind":"typeIdentifier","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getRelease\/Input\/Query-swift.struct","preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO5InputV5QueryV"},{"text":" = .init(), ","kind":"text"},{"text":"headers","kind":"externalParam"},{"text":": ","kind":"text"},{"text":"Operations","kind":"typeIdentifier","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations","preciseIdentifier":"s:14DiscogsService10OperationsO"},{"text":".","kind":"text"},{"text":"getRelease","kind":"typeIdentifier","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getRelease","preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO"},{"text":".","kind":"text"},{"text":"Input","kind":"typeIdentifier","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getRelease\/Input","preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO5InputV"},{"kind":"text","text":"."},{"preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO5InputV7HeadersV","kind":"typeIdentifier","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getRelease\/Input\/Headers-swift.struct","text":"Headers"},{"kind":"text","text":" = .init()) "},{"kind":"keyword","text":"async"},{"kind":"text","text":" "},{"kind":"keyword","text":"throws"},{"kind":"text","text":" -> "},{"text":"Operations","kind":"typeIdentifier","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations","preciseIdentifier":"s:14DiscogsService10OperationsO"},{"text":".","kind":"text"},{"preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO","kind":"typeIdentifier","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getRelease","text":"getRelease"},{"text":".","kind":"text"},{"preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO6OutputO","kind":"typeIdentifier","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getRelease\/Output","text":"Output"}]}]},{"kind":"content","content":[{"text":"Discussion","level":2,"type":"heading","anchor":"discussion"},{"type":"paragraph","inlineContent":[{"type":"text","text":"Retrieves details for a specific release."}]},{"style":"note","name":"Remark","type":"aside","content":[{"type":"paragraph","inlineContent":[{"type":"text","text":"HTTP "},{"code":"GET \/releases\/{release_id}","type":"codeVoice"},{"type":"text","text":"."}]}]},{"style":"note","name":"Remark","type":"aside","content":[{"type":"paragraph","inlineContent":[{"type":"text","text":"Generated from "},{"code":"#\/paths\/\/releases\/{release_id}\/get(getRelease)","type":"codeVoice"},{"type":"text","text":"."}]}]}]}],"references":{"doc://DiscogsService/documentation/DiscogsService":{"role":"collection","title":"DiscogsService","kind":"symbol","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService","abstract":[],"type":"topic","url":"\/documentation\/discogsservice"},"doc://DiscogsService/documentation/DiscogsService/Operations/getRelease/Input":{"fragments":[{"kind":"keyword","text":"struct"},{"kind":"text","text":" "},{"kind":"identifier","text":"Input"}],"role":"symbol","navigatorTitle":[{"kind":"identifier","text":"Input"}],"url":"\/documentation\/discogsservice\/operations\/getrelease\/input","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getRelease\/Input","abstract":[],"kind":"symbol","title":"Operations.getRelease.Input","type":"topic"},"doc://DiscogsService/documentation/DiscogsService/Operations/getRelease":{"abstract":[{"text":"Get information about a release","type":"text"}],"fragments":[{"kind":"keyword","text":"enum"},{"kind":"text","text":" "},{"kind":"identifier","text":"getRelease"}],"url":"\/documentation\/discogsservice\/operations\/getrelease","title":"Operations.getRelease","role":"symbol","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getRelease","kind":"symbol","type":"topic","navigatorTitle":[{"kind":"identifier","text":"getRelease"}]},"doc://DiscogsService/documentation/DiscogsService/Operations/getRelease/Input/Headers-swift.struct":{"fragments":[{"kind":"keyword","text":"struct"},{"kind":"text","text":" "},{"kind":"identifier","text":"Headers"}],"role":"symbol","navigatorTitle":[{"kind":"identifier","text":"Headers"}],"url":"\/documentation\/discogsservice\/operations\/getrelease\/input\/headers-swift.struct","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getRelease\/Input\/Headers-swift.struct","abstract":[],"kind":"symbol","title":"Operations.getRelease.Input.Headers","type":"topic"},"doc://DiscogsService/documentation/DiscogsService/APIProtocol/getRelease(path:query:headers:)":{"abstract":[{"text":"Get information about a release","type":"text"}],"kind":"symbol","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/APIProtocol\/getRelease(path:query:headers:)","role":"symbol","title":"getRelease(path:query:headers:)","type":"topic","url":"\/documentation\/discogsservice\/apiprotocol\/getrelease(path:query:headers:)","fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"getRelease"},{"kind":"text","text":"("},{"kind":"externalParam","text":"path"},{"kind":"text","text":": "},{"kind":"typeIdentifier","text":"Operations","preciseIdentifier":"s:14DiscogsService10OperationsO"},{"kind":"text","text":"."},{"kind":"typeIdentifier","text":"getRelease","preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO"},{"kind":"text","text":"."},{"kind":"typeIdentifier","text":"Input","preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO5InputV"},{"kind":"text","text":"."},{"kind":"typeIdentifier","text":"Path","preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO5InputV4PathV"},{"kind":"text","text":", "},{"kind":"externalParam","text":"query"},{"kind":"text","text":": "},{"kind":"typeIdentifier","text":"Operations","preciseIdentifier":"s:14DiscogsService10OperationsO"},{"kind":"text","text":"."},{"kind":"typeIdentifier","text":"getRelease","preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO"},{"kind":"text","text":"."},{"kind":"typeIdentifier","text":"Input","preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO5InputV"},{"kind":"text","text":"."},{"kind":"typeIdentifier","text":"Query","preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO5InputV5QueryV"},{"kind":"text","text":", "},{"kind":"externalParam","text":"headers"},{"kind":"text","text":": "},{"kind":"typeIdentifier","text":"Operations","preciseIdentifier":"s:14DiscogsService10OperationsO"},{"kind":"text","text":"."},{"kind":"typeIdentifier","text":"getRelease","preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO"},{"kind":"text","text":"."},{"kind":"typeIdentifier","text":"Input","preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO5InputV"},{"kind":"text","text":"."},{"kind":"typeIdentifier","text":"Headers","preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO5InputV7HeadersV"},{"kind":"text","text":") "},{"kind":"keyword","text":"async"},{"kind":"text","text":" "},{"kind":"keyword","text":"throws"},{"kind":"text","text":" -> "},{"kind":"typeIdentifier","text":"Operations","preciseIdentifier":"s:14DiscogsService10OperationsO"},{"kind":"text","text":"."},{"kind":"typeIdentifier","text":"getRelease","preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO"},{"kind":"text","text":"."},{"kind":"typeIdentifier","text":"Output","preciseIdentifier":"s:14DiscogsService10OperationsO10getReleaseO6OutputO"}]},"doc://DiscogsService/documentation/DiscogsService/APIProtocol":{"abstract":[{"type":"text","text":"A type that performs HTTP operations defined by the OpenAPI document."}],"fragments":[{"text":"protocol","kind":"keyword"},{"text":" ","kind":"text"},{"text":"APIProtocol","kind":"identifier"}],"url":"\/documentation\/discogsservice\/apiprotocol","title":"APIProtocol","role":"symbol","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/APIProtocol","kind":"symbol","type":"topic","navigatorTitle":[{"text":"APIProtocol","kind":"identifier"}]},"doc://DiscogsService/documentation/DiscogsService/Operations/getRelease/Input/Query-swift.struct":{"abstract":[],"kind":"symbol","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getRelease\/Input\/Query-swift.struct","role":"symbol","title":"Operations.getRelease.Input.Query","navigatorTitle":[{"kind":"identifier","text":"Query"}],"type":"topic","url":"\/documentation\/discogsservice\/operations\/getrelease\/input\/query-swift.struct","fragments":[{"kind":"keyword","text":"struct"},{"kind":"text","text":" "},{"kind":"identifier","text":"Query"}]},"doc://DiscogsService/documentation/DiscogsService/Operations/getRelease/Input/Path-swift.struct":{"role":"symbol","type":"topic","abstract":[],"kind":"symbol","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getRelease\/Input\/Path-swift.struct","url":"\/documentation\/discogsservice\/operations\/getrelease\/input\/path-swift.struct","navigatorTitle":[{"text":"Path","kind":"identifier"}],"title":"Operations.getRelease.Input.Path","fragments":[{"text":"struct","kind":"keyword"},{"kind":"text","text":" "},{"kind":"identifier","text":"Path"}]},"doc://DiscogsService/documentation/DiscogsService/Operations":{"fragments":[{"text":"enum","kind":"keyword"},{"text":" ","kind":"text"},{"text":"Operations","kind":"identifier"}],"role":"symbol","navigatorTitle":[{"text":"Operations","kind":"identifier"}],"title":"Operations","abstract":[{"text":"API operations, with input and output types, generated from ","type":"text"},{"type":"codeVoice","code":"#\/paths"},{"type":"text","text":" in the OpenAPI document."}],"identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations","kind":"symbol","type":"topic","url":"\/documentation\/discogsservice\/operations"},"doc://DiscogsService/documentation/DiscogsService/Operations/getRelease/Output":{"title":"Operations.getRelease.Output","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getRelease\/Output","navigatorTitle":[{"kind":"identifier","text":"Output"}],"abstract":[],"type":"topic","fragments":[{"text":"enum","kind":"keyword"},{"kind":"text","text":" "},{"text":"Output","kind":"identifier"}],"role":"symbol","url":"\/documentation\/discogsservice\/operations\/getrelease\/output","kind":"symbol"}}} |