diff --git a/docs/Repository.md b/docs/Repository.md
index bde5614..8e5bf93 100644
--- a/docs/Repository.md
+++ b/docs/Repository.md
@@ -39,6 +39,7 @@ Name | Type | Description | Notes
**internalTracker** | [**InternalTracker**](InternalTracker.md) | | [optional]
**language** | **String** | | [optional]
**languagesUrl** | **String** | | [optional]
+**licenses** | **List<String>** | | [optional]
**link** | **String** | | [optional]
**mirror** | **Boolean** | | [optional]
**mirrorInterval** | **String** | | [optional]
diff --git a/docs/RepositoryApi.md b/docs/RepositoryApi.md
index 8e7c165..666ec79 100644
--- a/docs/RepositoryApi.md
+++ b/docs/RepositoryApi.md
@@ -94,6 +94,7 @@ Method | HTTP request | Description
[**repoGetKey**](RepositoryApi.md#repoGetKey) | **GET** repos/{owner}/{repo}/keys/{id} | Get a repository's key by id
[**repoGetLanguages**](RepositoryApi.md#repoGetLanguages) | **GET** repos/{owner}/{repo}/languages | Get languages and number of bytes of code written
[**repoGetLatestRelease**](RepositoryApi.md#repoGetLatestRelease) | **GET** repos/{owner}/{repo}/releases/latest | Gets the most recent non-prerelease, non-draft release of a repository, sorted by created_at
+[**repoGetLicenses**](RepositoryApi.md#repoGetLicenses) | **GET** repos/{owner}/{repo}/licenses | Get repo licenses
[**repoGetNote**](RepositoryApi.md#repoGetNote) | **GET** repos/{owner}/{repo}/git/notes/{sha} | Get a note corresponding to a single commit from a repository
[**repoGetPullRequest**](RepositoryApi.md#repoGetPullRequest) | **GET** repos/{owner}/{repo}/pulls/{index} | Get a pull request
[**repoGetPullRequestByBaseHead**](RepositoryApi.md#repoGetPullRequestByBaseHead) | **GET** repos/{owner}/{repo}/pulls/{base}/{head} | Get a pull request by base and head
@@ -8505,6 +8506,95 @@ Name | Type | Description | Notes
[AccessToken](../README.md#AccessToken)[AuthorizationHeaderToken](../README.md#AuthorizationHeaderToken)[BasicAuth](../README.md#BasicAuth)[SudoHeader](../README.md#SudoHeader)[SudoParam](../README.md#SudoParam)[TOTPHeader](../README.md#TOTPHeader)[Token](../README.md#Token)
+### HTTP request headers
+
+ - **Content-Type**: Not defined
+ - **Accept**: application/json
+
+
+# **repoGetLicenses**
+> List<String> repoGetLicenses(owner, repo)
+
+Get repo licenses
+
+### Example
+```java
+// Import classes:
+//import org.gitnex.tea4j.v2.ApiClient;
+//import org.gitnex.tea4j.v2.ApiException;
+//import org.gitnex.tea4j.v2.Configuration;
+//import org.gitnex.tea4j.v2.auth.*;
+//import org.gitnex.tea4j.v2.apis.RepositoryApi;
+
+ApiClient defaultClient = Configuration.getDefaultApiClient();
+
+// Configure API key authorization: AccessToken
+ApiKeyAuth AccessToken = (ApiKeyAuth) defaultClient.getAuthentication("AccessToken");
+AccessToken.setApiKey("YOUR API KEY");
+// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
+//AccessToken.setApiKeyPrefix("Token");
+
+// Configure API key authorization: AuthorizationHeaderToken
+ApiKeyAuth AuthorizationHeaderToken = (ApiKeyAuth) defaultClient.getAuthentication("AuthorizationHeaderToken");
+AuthorizationHeaderToken.setApiKey("YOUR API KEY");
+// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
+//AuthorizationHeaderToken.setApiKeyPrefix("Token");
+// Configure HTTP basic authorization: BasicAuth
+HttpBasicAuth BasicAuth = (HttpBasicAuth) defaultClient.getAuthentication("BasicAuth");
+BasicAuth.setUsername("YOUR USERNAME");
+BasicAuth.setPassword("YOUR PASSWORD");
+
+// Configure API key authorization: SudoHeader
+ApiKeyAuth SudoHeader = (ApiKeyAuth) defaultClient.getAuthentication("SudoHeader");
+SudoHeader.setApiKey("YOUR API KEY");
+// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
+//SudoHeader.setApiKeyPrefix("Token");
+
+// Configure API key authorization: SudoParam
+ApiKeyAuth SudoParam = (ApiKeyAuth) defaultClient.getAuthentication("SudoParam");
+SudoParam.setApiKey("YOUR API KEY");
+// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
+//SudoParam.setApiKeyPrefix("Token");
+
+// Configure API key authorization: TOTPHeader
+ApiKeyAuth TOTPHeader = (ApiKeyAuth) defaultClient.getAuthentication("TOTPHeader");
+TOTPHeader.setApiKey("YOUR API KEY");
+// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
+//TOTPHeader.setApiKeyPrefix("Token");
+
+// Configure API key authorization: Token
+ApiKeyAuth Token = (ApiKeyAuth) defaultClient.getAuthentication("Token");
+Token.setApiKey("YOUR API KEY");
+// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
+//Token.setApiKeyPrefix("Token");
+
+RepositoryApi apiInstance = new RepositoryApi();
+String owner = "owner_example"; // String | owner of the repo
+String repo = "repo_example"; // String | name of the repo
+try {
+ List result = apiInstance.repoGetLicenses(owner, repo);
+ System.out.println(result);
+} catch (ApiException e) {
+ System.err.println("Exception when calling RepositoryApi#repoGetLicenses");
+ e.printStackTrace();
+}
+```
+
+### Parameters
+
+Name | Type | Description | Notes
+------------- | ------------- | ------------- | -------------
+ **owner** | **String**| owner of the repo |
+ **repo** | **String**| name of the repo |
+
+### Return type
+
+**List<String>**
+
+### Authorization
+
+[AccessToken](../README.md#AccessToken)[AuthorizationHeaderToken](../README.md#AuthorizationHeaderToken)[BasicAuth](../README.md#BasicAuth)[SudoHeader](../README.md#SudoHeader)[SudoParam](../README.md#SudoParam)[TOTPHeader](../README.md#TOTPHeader)[Token](../README.md#Token)
+
### HTTP request headers
- **Content-Type**: Not defined
diff --git a/src/main/java/org/gitnex/tea4j/v2/apis/RepositoryApi.java b/src/main/java/org/gitnex/tea4j/v2/apis/RepositoryApi.java
index d3a928a..d82cce6 100644
--- a/src/main/java/org/gitnex/tea4j/v2/apis/RepositoryApi.java
+++ b/src/main/java/org/gitnex/tea4j/v2/apis/RepositoryApi.java
@@ -1469,6 +1469,17 @@ public interface RepositoryApi {
Call repoGetLatestRelease(
@retrofit2.http.Path("owner") String owner, @retrofit2.http.Path("repo") String repo);
+ /**
+ * Get repo licenses
+ *
+ * @param owner owner of the repo (required)
+ * @param repo name of the repo (required)
+ * @return Call<List<String>>
+ */
+ @GET("repos/{owner}/{repo}/licenses")
+ Call> repoGetLicenses(
+ @retrofit2.http.Path("owner") String owner, @retrofit2.http.Path("repo") String repo);
+
/**
* Get a note corresponding to a single commit from a repository
*
diff --git a/src/main/java/org/gitnex/tea4j/v2/models/Repository.java b/src/main/java/org/gitnex/tea4j/v2/models/Repository.java
index d741544..c125470 100644
--- a/src/main/java/org/gitnex/tea4j/v2/models/Repository.java
+++ b/src/main/java/org/gitnex/tea4j/v2/models/Repository.java
@@ -138,6 +138,9 @@ public class Repository implements Serializable {
@SerializedName("languages_url")
private String languagesUrl = null;
+ @SerializedName("licenses")
+ private List licenses = null;
+
@SerializedName("link")
private String link = null;
@@ -942,6 +945,33 @@ public class Repository implements Serializable {
this.languagesUrl = languagesUrl;
}
+ public Repository licenses(List licenses) {
+ this.licenses = licenses;
+ return this;
+ }
+
+ public Repository addLicensesItem(String licensesItem) {
+ if (this.licenses == null) {
+ this.licenses = new ArrayList<>();
+ }
+ this.licenses.add(licensesItem);
+ return this;
+ }
+
+ /**
+ * Get licenses
+ *
+ * @return licenses
+ */
+ @Schema(description = "")
+ public List getLicenses() {
+ return licenses;
+ }
+
+ public void setLicenses(List licenses) {
+ this.licenses = licenses;
+ }
+
public Repository link(String link) {
this.link = link;
return this;
@@ -1471,6 +1501,7 @@ public class Repository implements Serializable {
&& Objects.equals(this.internalTracker, repository.internalTracker)
&& Objects.equals(this.language, repository.language)
&& Objects.equals(this.languagesUrl, repository.languagesUrl)
+ && Objects.equals(this.licenses, repository.licenses)
&& Objects.equals(this.link, repository.link)
&& Objects.equals(this.mirror, repository.mirror)
&& Objects.equals(this.mirrorInterval, repository.mirrorInterval)
@@ -1537,6 +1568,7 @@ public class Repository implements Serializable {
internalTracker,
language,
languagesUrl,
+ licenses,
link,
mirror,
mirrorInterval,
@@ -1615,6 +1647,7 @@ public class Repository implements Serializable {
sb.append(" internalTracker: ").append(toIndentedString(internalTracker)).append("\n");
sb.append(" language: ").append(toIndentedString(language)).append("\n");
sb.append(" languagesUrl: ").append(toIndentedString(languagesUrl)).append("\n");
+ sb.append(" licenses: ").append(toIndentedString(licenses)).append("\n");
sb.append(" link: ").append(toIndentedString(link)).append("\n");
sb.append(" mirror: ").append(toIndentedString(mirror)).append("\n");
sb.append(" mirrorInterval: ").append(toIndentedString(mirrorInterval)).append("\n");