org.gitlab4j.api.MetadataApi Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of gitlab4j-api Show documentation
Show all versions of gitlab4j-api Show documentation
GitLab4J-API (gitlab4j-api) provides a full featured Java client library for working with GitLab repositories and servers via the GitLab REST API.
package org.gitlab4j.api;
import jakarta.ws.rs.core.Response;
import jakarta.ws.rs.core.Response.Status;
import org.gitlab4j.api.models.Metadata;
/**
* This class implements the client side API for the Gitlab metadata call.
*
* @see Metadata API at Gitlab
*/
public class MetadataApi extends AbstractApi {
public MetadataApi(GitLabApi gitLabApi) {
super(gitLabApi);
}
/**
* Get Gitlab metadata
*
* Gitlab Endpoint: GET /metadata
*
* @return Gitlab metadata
* @throws GitLabApiException if any exception occurs
*/
public Metadata getMetadata() throws GitLabApiException {
Response response = get(Status.OK, null, "metadata");
return (response.readEntity(Metadata.class));
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy