All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.lockss.laaws.mdq.api.UrlsApi Maven / Gradle / Ivy

The newest version!
/**
 * NOTE: This class is auto generated by the swagger code generator program (3.0.52).
 * https://github.com/swagger-api/swagger-codegen
 * Do not edit the class manually.
 */
package org.lockss.laaws.mdq.api;

import org.lockss.laaws.mdq.model.ErrorResult;
import org.lockss.laaws.mdq.model.UrlInfo;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.Parameter;
import io.swagger.v3.oas.annotations.enums.ParameterIn;
import io.swagger.v3.oas.annotations.responses.ApiResponses;
import io.swagger.v3.oas.annotations.responses.ApiResponse;
import io.swagger.v3.oas.annotations.media.ArraySchema;
import io.swagger.v3.oas.annotations.media.Content;
import io.swagger.v3.oas.annotations.media.Schema;
import io.swagger.v3.oas.annotations.security.SecurityRequirement;
import org.springframework.http.ResponseEntity;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestHeader;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RequestPart;
import org.springframework.web.multipart.MultipartFile;
import org.springframework.web.bind.annotation.CookieValue;

import jakarta.validation.Valid;
import jakarta.validation.constraints.*;
import java.util.List;
import java.util.Map;


@Validated
public interface UrlsApi {

    UrlsApiDelegate getDelegate();

    @Operation(summary = "Gets the URL for a DOI", description = "Provides the URL for a DOI given the DOI", security = {
        @SecurityRequirement(name = "basicAuth")    }, tags={ "urls" })
    @ApiResponses(value = { 
        @ApiResponse(responseCode = "200", description = "The URL for the specified DOI", content = @Content(mediaType = "application/json", schema = @Schema(implementation = UrlInfo.class))),
        
        @ApiResponse(responseCode = "200", description = "The resulting error payload.", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ErrorResult.class))) })
    @RequestMapping(value = "/urls/doi",
        produces = { "application/json" }, 
        method = RequestMethod.GET)
    default ResponseEntity getUrlsDoi(@NotNull @Parameter(in = ParameterIn.QUERY, description = "The DOI for which the URL is requested" ,required=true,schema=@Schema()) @Valid @RequestParam(value = "doi", required = true) String doi
) {
        return getDelegate().getUrlsDoi(doi);
    }


    @Operation(summary = "Performs an OpenURL query", description = "Provides the URL that results from performing an OpenURL query. With query parameters inline", security = {
        @SecurityRequirement(name = "basicAuth")    }, tags={ "urls" })
    @ApiResponses(value = { 
        @ApiResponse(responseCode = "200", description = "The data related to the performed OpenURL query", content = @Content(mediaType = "application/json", schema = @Schema(implementation = UrlInfo.class))),
        
        @ApiResponse(responseCode = "200", description = "The resulting error payload.", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ErrorResult.class))) })
    @RequestMapping(value = "/urls/openurl",
        produces = { "application/json" }, 
        method = RequestMethod.GET)
    default ResponseEntity getUrlsOpenUrl(@NotNull @Parameter(in = ParameterIn.QUERY, description = "The OpenURL parameters" ,required=true,schema=@Schema()) @Valid @RequestParam(value = "params", required = true) List params
) {
        return getDelegate().getUrlsOpenUrl(params);
    }

}





© 2015 - 2024 Weber Informatics LLC | Privacy Policy