Files
discogs-service/docs/data/documentation/discogsservice/apiprotocol/getreleaserating(path:headers:).json
T
javier 428eedd89d Implemented the Services and Database GET endpoints (#2)
This PR contains the work done to include the define the information sections of the `OpenAPI` specification document and all the `GET` endpoints of the _Service_ and _Database_ categories.

The following endpoints have been defined in the document, and also tested manually with `Swift`:
* GET `/`
* GET `/artists/{artist_id}`
* GET `/artists/{artist_id}/releases`
* GET `/labels/{label_id}`
* GET `/labels/{label_id}/releases`
* GET `/masters/{master_id}`
* GET `/masters/{master_id}/versions`
* GET `/releases/{release_id}`
* GET `/releases/{release_id}/rating`
* GET `/releases/{release_id}/rating/{username}`
* GET `/releases/{release_id}/stats`
* GET `/database/search`

In addition, a first version of the _Github Pages_ documentation has been generated from the `DocC` documentation catalog, and the generated Swift code from the `openapi.yaml` file.

Reviewed-on: #2
Co-authored-by: Javier Cicchelli <javier@rock-n-code.com>
Co-committed-by: Javier Cicchelli <javier@rock-n-code.com>
2025-10-09 23:51:39 +00:00

1 line
13 KiB
JSON

{"hierarchy":{"paths":[["doc:\/\/DiscogsService\/documentation\/DiscogsService","doc:\/\/DiscogsService\/documentation\/DiscogsService\/APIProtocol"]]},"schemaVersion":{"major":0,"patch":0,"minor":3},"primaryContentSections":[{"kind":"declarations","declarations":[{"tokens":[{"text":"func","kind":"keyword"},{"text":" ","kind":"text"},{"text":"getReleaseRating","kind":"identifier"},{"text":"(","kind":"text"},{"text":"path","kind":"externalParam"},{"text":": ","kind":"text"},{"text":"Operations","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations","preciseIdentifier":"s:14DiscogsService10OperationsO","kind":"typeIdentifier"},{"text":".","kind":"text"},{"text":"getReleaseRating","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getReleaseRating","preciseIdentifier":"s:14DiscogsService10OperationsO16getReleaseRatingO","kind":"typeIdentifier"},{"text":".","kind":"text"},{"preciseIdentifier":"s:14DiscogsService10OperationsO16getReleaseRatingO5InputV","text":"Input","kind":"typeIdentifier","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getReleaseRating\/Input"},{"text":".","kind":"text"},{"preciseIdentifier":"s:14DiscogsService10OperationsO16getReleaseRatingO5InputV4PathV","text":"Path","kind":"typeIdentifier","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getReleaseRating\/Input\/Path-swift.struct"},{"text":", ","kind":"text"},{"text":"headers","kind":"externalParam"},{"text":": ","kind":"text"},{"text":"Operations","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations","preciseIdentifier":"s:14DiscogsService10OperationsO","kind":"typeIdentifier"},{"text":".","kind":"text"},{"preciseIdentifier":"s:14DiscogsService10OperationsO16getReleaseRatingO","text":"getReleaseRating","kind":"typeIdentifier","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getReleaseRating"},{"text":".","kind":"text"},{"preciseIdentifier":"s:14DiscogsService10OperationsO16getReleaseRatingO5InputV","text":"Input","kind":"typeIdentifier","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getReleaseRating\/Input"},{"text":".","kind":"text"},{"text":"Headers","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getReleaseRating\/Input\/Headers-swift.struct","preciseIdentifier":"s:14DiscogsService10OperationsO16getReleaseRatingO5InputV7HeadersV","kind":"typeIdentifier"},{"text":" = .init()) ","kind":"text"},{"text":"async","kind":"keyword"},{"text":" ","kind":"text"},{"text":"throws","kind":"keyword"},{"text":" -> ","kind":"text"},{"text":"Operations","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations","preciseIdentifier":"s:14DiscogsService10OperationsO","kind":"typeIdentifier"},{"text":".","kind":"text"},{"preciseIdentifier":"s:14DiscogsService10OperationsO16getReleaseRatingO","text":"getReleaseRating","kind":"typeIdentifier","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getReleaseRating"},{"text":".","kind":"text"},{"preciseIdentifier":"s:14DiscogsService10OperationsO16getReleaseRatingO6OutputO","text":"Output","kind":"typeIdentifier","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getReleaseRating\/Output"}],"languages":["swift"],"platforms":["macOS"]}]},{"kind":"content","content":[{"type":"heading","text":"Discussion","level":2,"anchor":"discussion"},{"inlineContent":[{"type":"text","text":"Retrieves the average rating and the total number of user ratings for a given release."}],"type":"paragraph"},{"type":"aside","name":"Remark","style":"note","content":[{"inlineContent":[{"type":"text","text":"HTTP "},{"type":"codeVoice","code":"GET \/releases\/{release_id}\/rating"},{"type":"text","text":"."}],"type":"paragraph"}]},{"type":"aside","style":"note","name":"Remark","content":[{"inlineContent":[{"text":"Generated from ","type":"text"},{"type":"codeVoice","code":"#\/paths\/\/releases\/{release_id}\/rating\/get(getReleaseRating)"},{"text":".","type":"text"}],"type":"paragraph"}]}]}],"sections":[],"metadata":{"fragments":[{"text":"func","kind":"keyword"},{"text":" ","kind":"text"},{"text":"getReleaseRating","kind":"identifier"},{"text":"(","kind":"text"},{"text":"path","kind":"externalParam"},{"text":": ","kind":"text"},{"text":"Operations","preciseIdentifier":"s:14DiscogsService10OperationsO","kind":"typeIdentifier"},{"text":".","kind":"text"},{"text":"getReleaseRating","preciseIdentifier":"s:14DiscogsService10OperationsO16getReleaseRatingO","kind":"typeIdentifier"},{"text":".","kind":"text"},{"text":"Input","preciseIdentifier":"s:14DiscogsService10OperationsO16getReleaseRatingO5InputV","kind":"typeIdentifier"},{"text":".","kind":"text"},{"text":"Path","preciseIdentifier":"s:14DiscogsService10OperationsO16getReleaseRatingO5InputV4PathV","kind":"typeIdentifier"},{"text":", ","kind":"text"},{"text":"headers","kind":"externalParam"},{"text":": ","kind":"text"},{"text":"Operations","preciseIdentifier":"s:14DiscogsService10OperationsO","kind":"typeIdentifier"},{"text":".","kind":"text"},{"text":"getReleaseRating","preciseIdentifier":"s:14DiscogsService10OperationsO16getReleaseRatingO","kind":"typeIdentifier"},{"text":".","kind":"text"},{"text":"Input","preciseIdentifier":"s:14DiscogsService10OperationsO16getReleaseRatingO5InputV","kind":"typeIdentifier"},{"text":".","kind":"text"},{"text":"Headers","preciseIdentifier":"s:14DiscogsService10OperationsO16getReleaseRatingO5InputV7HeadersV","kind":"typeIdentifier"},{"text":") ","kind":"text"},{"text":"async","kind":"keyword"},{"text":" ","kind":"text"},{"text":"throws","kind":"keyword"},{"text":" -> ","kind":"text"},{"text":"Operations","preciseIdentifier":"s:14DiscogsService10OperationsO","kind":"typeIdentifier"},{"text":".","kind":"text"},{"text":"getReleaseRating","preciseIdentifier":"s:14DiscogsService10OperationsO16getReleaseRatingO","kind":"typeIdentifier"},{"text":".","kind":"text"},{"text":"Output","preciseIdentifier":"s:14DiscogsService10OperationsO16getReleaseRatingO6OutputO","kind":"typeIdentifier"}],"modules":[{"name":"DiscogsService"}],"role":"symbol","extendedModule":"DiscogsService","symbolKind":"method","externalID":"s:14DiscogsService11APIProtocolPAAE16getReleaseRating4path7headersAA10OperationsOADO6OutputOAI5InputV4PathV_AM7HeadersVtYaKF","roleHeading":"Instance Method","title":"getReleaseRating(path:headers:)"},"kind":"symbol","identifier":{"url":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/APIProtocol\/getReleaseRating(path:headers:)","interfaceLanguage":"swift"},"abstract":[{"type":"text","text":"Get information about a rating of release."}],"variants":[{"paths":["\/documentation\/discogsservice\/apiprotocol\/getreleaserating(path:headers:)"],"traits":[{"interfaceLanguage":"swift"}]}],"references":{"doc://DiscogsService/documentation/DiscogsService/Operations/getReleaseRating":{"url":"\/documentation\/discogsservice\/operations\/getreleaserating","abstract":[{"text":"Get information about a rating of release.","type":"text"}],"identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getReleaseRating","kind":"symbol","role":"symbol","title":"Operations.getReleaseRating","type":"topic","fragments":[{"kind":"keyword","text":"enum"},{"text":" ","kind":"text"},{"text":"getReleaseRating","kind":"identifier"}],"navigatorTitle":[{"text":"getReleaseRating","kind":"identifier"}]},"doc://DiscogsService/documentation/DiscogsService/Operations/getReleaseRating/Input/Path-swift.struct":{"role":"symbol","type":"topic","abstract":[],"identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getReleaseRating\/Input\/Path-swift.struct","url":"\/documentation\/discogsservice\/operations\/getreleaserating\/input\/path-swift.struct","title":"Operations.getReleaseRating.Input.Path","kind":"symbol","navigatorTitle":[{"text":"Path","kind":"identifier"}],"fragments":[{"text":"struct","kind":"keyword"},{"text":" ","kind":"text"},{"kind":"identifier","text":"Path"}]},"doc://DiscogsService/documentation/DiscogsService/Operations/getReleaseRating/Output":{"navigatorTitle":[{"text":"Output","kind":"identifier"}],"title":"Operations.getReleaseRating.Output","abstract":[],"role":"symbol","type":"topic","url":"\/documentation\/discogsservice\/operations\/getreleaserating\/output","kind":"symbol","fragments":[{"text":"enum","kind":"keyword"},{"text":" ","kind":"text"},{"text":"Output","kind":"identifier"}],"identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getReleaseRating\/Output"},"doc://DiscogsService/documentation/DiscogsService/Operations/getReleaseRating/Input":{"fragments":[{"text":"struct","kind":"keyword"},{"text":" ","kind":"text"},{"text":"Input","kind":"identifier"}],"type":"topic","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getReleaseRating\/Input","navigatorTitle":[{"text":"Input","kind":"identifier"}],"title":"Operations.getReleaseRating.Input","role":"symbol","abstract":[],"kind":"symbol","url":"\/documentation\/discogsservice\/operations\/getreleaserating\/input"},"doc://DiscogsService/documentation/DiscogsService/Operations":{"navigatorTitle":[{"kind":"identifier","text":"Operations"}],"fragments":[{"kind":"keyword","text":"enum"},{"kind":"text","text":" "},{"kind":"identifier","text":"Operations"}],"url":"\/documentation\/discogsservice\/operations","role":"symbol","type":"topic","kind":"symbol","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations","abstract":[{"text":"API operations, with input and output types, generated from ","type":"text"},{"code":"#\/paths","type":"codeVoice"},{"text":" in the OpenAPI document.","type":"text"}],"title":"Operations"},"doc://DiscogsService/documentation/DiscogsService":{"url":"\/documentation\/discogsservice","abstract":[],"identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService","kind":"symbol","role":"collection","type":"topic","title":"DiscogsService"},"doc://DiscogsService/documentation/DiscogsService/APIProtocol":{"navigatorTitle":[{"kind":"identifier","text":"APIProtocol"}],"fragments":[{"kind":"keyword","text":"protocol"},{"kind":"text","text":" "},{"kind":"identifier","text":"APIProtocol"}],"url":"\/documentation\/discogsservice\/apiprotocol","role":"symbol","type":"topic","kind":"symbol","identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/APIProtocol","abstract":[{"type":"text","text":"A type that performs HTTP operations defined by the OpenAPI document."}],"title":"APIProtocol"},"doc://DiscogsService/documentation/DiscogsService/APIProtocol/getReleaseRating(path:headers:)":{"role":"symbol","type":"topic","abstract":[{"type":"text","text":"Get information about a rating of release."}],"identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/APIProtocol\/getReleaseRating(path:headers:)","title":"getReleaseRating(path:headers:)","url":"\/documentation\/discogsservice\/apiprotocol\/getreleaserating(path:headers:)","kind":"symbol","fragments":[{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"getReleaseRating"},{"kind":"text","text":"("},{"kind":"externalParam","text":"path"},{"kind":"text","text":": "},{"preciseIdentifier":"s:14DiscogsService10OperationsO","kind":"typeIdentifier","text":"Operations"},{"kind":"text","text":"."},{"preciseIdentifier":"s:14DiscogsService10OperationsO16getReleaseRatingO","kind":"typeIdentifier","text":"getReleaseRating"},{"kind":"text","text":"."},{"preciseIdentifier":"s:14DiscogsService10OperationsO16getReleaseRatingO5InputV","kind":"typeIdentifier","text":"Input"},{"kind":"text","text":"."},{"preciseIdentifier":"s:14DiscogsService10OperationsO16getReleaseRatingO5InputV4PathV","kind":"typeIdentifier","text":"Path"},{"kind":"text","text":", "},{"kind":"externalParam","text":"headers"},{"kind":"text","text":": "},{"preciseIdentifier":"s:14DiscogsService10OperationsO","kind":"typeIdentifier","text":"Operations"},{"kind":"text","text":"."},{"preciseIdentifier":"s:14DiscogsService10OperationsO16getReleaseRatingO","kind":"typeIdentifier","text":"getReleaseRating"},{"kind":"text","text":"."},{"preciseIdentifier":"s:14DiscogsService10OperationsO16getReleaseRatingO5InputV","kind":"typeIdentifier","text":"Input"},{"kind":"text","text":"."},{"preciseIdentifier":"s:14DiscogsService10OperationsO16getReleaseRatingO5InputV7HeadersV","kind":"typeIdentifier","text":"Headers"},{"kind":"text","text":") "},{"kind":"keyword","text":"async"},{"kind":"text","text":" "},{"kind":"keyword","text":"throws"},{"kind":"text","text":" -> "},{"preciseIdentifier":"s:14DiscogsService10OperationsO","kind":"typeIdentifier","text":"Operations"},{"kind":"text","text":"."},{"preciseIdentifier":"s:14DiscogsService10OperationsO16getReleaseRatingO","kind":"typeIdentifier","text":"getReleaseRating"},{"kind":"text","text":"."},{"preciseIdentifier":"s:14DiscogsService10OperationsO16getReleaseRatingO6OutputO","kind":"typeIdentifier","text":"Output"}]},"doc://DiscogsService/documentation/DiscogsService/Operations/getReleaseRating/Input/Headers-swift.struct":{"role":"symbol","type":"topic","abstract":[],"identifier":"doc:\/\/DiscogsService\/documentation\/DiscogsService\/Operations\/getReleaseRating\/Input\/Headers-swift.struct","url":"\/documentation\/discogsservice\/operations\/getreleaserating\/input\/headers-swift.struct","title":"Operations.getReleaseRating.Input.Headers","kind":"symbol","navigatorTitle":[{"text":"Headers","kind":"identifier"}],"fragments":[{"text":"struct","kind":"keyword"},{"text":" ","kind":"text"},{"text":"Headers","kind":"identifier"}]}}}