Skip to content

Commit 59b3d0f

Browse files
committed
Update to 225c489
1 parent 2d832e2 commit 59b3d0f

File tree

85 files changed

+789
-118
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

85 files changed

+789
-118
lines changed

docs/DeployKey.md

+3
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,12 @@
55
Name | Type | Description | Notes
66
------------ | ------------- | ------------- | -------------
77
**createdAt** | [**OffsetDateTime**](OffsetDateTime.md) | | [optional]
8+
**fingerprint** | **String** | | [optional]
89
**id** | **Long** | | [optional]
910
**key** | **String** | | [optional]
11+
**keyId** | **Long** | | [optional]
1012
**readOnly** | **Boolean** | | [optional]
13+
**repository** | [**Repository**](Repository.md) | | [optional]
1114
**title** | **String** | | [optional]
1215
**url** | **String** | | [optional]
1316

docs/PublicKey.md

+3
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,11 @@ Name | Type | Description | Notes
88
**fingerprint** | **String** | | [optional]
99
**id** | **Long** | | [optional]
1010
**key** | **String** | | [optional]
11+
**keyType** | **String** | | [optional]
12+
**readOnly** | **Boolean** | | [optional]
1113
**title** | **String** | | [optional]
1214
**url** | **String** | | [optional]
15+
**user** | [**User**](User.md) | | [optional]
1316

1417

1518

docs/Repository.md

+1
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
## Properties
55
Name | Type | Description | Notes
66
------------ | ------------- | ------------- | -------------
7+
**archived** | **Boolean** | | [optional]
78
**cloneUrl** | **String** | | [optional]
89
**createdAt** | [**OffsetDateTime**](OffsetDateTime.md) | | [optional]
910
**defaultBranch** | **String** | | [optional]

docs/RepositoryApi.md

+6-2
Original file line numberDiff line numberDiff line change
@@ -3149,7 +3149,7 @@ Name | Type | Description | Notes
31493149

31503150
<a name="repoListKeys"></a>
31513151
# **repoListKeys**
3152-
> List&lt;DeployKey&gt; repoListKeys(owner, repo)
3152+
> List&lt;DeployKey&gt; repoListKeys(owner, repo, keyId, fingerprint)
31533153
31543154
List a repository&#39;s keys
31553155

@@ -3202,8 +3202,10 @@ Token.setApiKey("YOUR API KEY");
32023202
RepositoryApi apiInstance = new RepositoryApi();
32033203
String owner = "owner_example"; // String | owner of the repo
32043204
String repo = "repo_example"; // String | name of the repo
3205+
Integer keyId = 56; // Integer | the key_id to search for
3206+
String fingerprint = "fingerprint_example"; // String | fingerprint of the key
32053207
try {
3206-
List<DeployKey> result = apiInstance.repoListKeys(owner, repo);
3208+
List<DeployKey> result = apiInstance.repoListKeys(owner, repo, keyId, fingerprint);
32073209
System.out.println(result);
32083210
} catch (ApiException e) {
32093211
System.err.println("Exception when calling RepositoryApi#repoListKeys");
@@ -3217,6 +3219,8 @@ Name | Type | Description | Notes
32173219
------------- | ------------- | ------------- | -------------
32183220
**owner** | **String**| owner of the repo |
32193221
**repo** | **String**| name of the repo |
3222+
**keyId** | **Integer**| the key_id to search for | [optional]
3223+
**fingerprint** | **String**| fingerprint of the key | [optional]
32203224

32213225
### Return type
32223226

docs/UserApi.md

+94-5
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ Method | HTTP request | Description
3232
[**userDeleteEmail**](UserApi.md#userDeleteEmail) | **DELETE** /user/emails | Delete email addresses
3333
[**userGet**](UserApi.md#userGet) | **GET** /users/{username} | Get a user
3434
[**userGetCurrent**](UserApi.md#userGetCurrent) | **GET** /user | Get the authenticated user
35+
[**userGetHeatmapData**](UserApi.md#userGetHeatmapData) | **GET** /users/{username}/heatmap | Get a user&#39;s heatmap
3536
[**userGetTokens**](UserApi.md#userGetTokens) | **GET** /users/{username}/tokens | List the authenticated user&#39;s access tokens
3637
[**userListEmails**](UserApi.md#userListEmails) | **GET** /user/emails | List the authenticated user&#39;s email addresses
3738
[**userListFollowers**](UserApi.md#userListFollowers) | **GET** /users/{username}/followers | List the given user&#39;s followers
@@ -1266,7 +1267,7 @@ This endpoint does not need any parameter.
12661267

12671268
<a name="userCurrentListKeys"></a>
12681269
# **userCurrentListKeys**
1269-
> List&lt;PublicKey&gt; userCurrentListKeys()
1270+
> List&lt;PublicKey&gt; userCurrentListKeys(fingerprint)
12701271
12711272
List the authenticated user&#39;s public keys
12721273

@@ -1317,8 +1318,9 @@ Token.setApiKey("YOUR API KEY");
13171318
//Token.setApiKeyPrefix("Token");
13181319

13191320
UserApi apiInstance = new UserApi();
1321+
String fingerprint = "fingerprint_example"; // String | fingerprint of the key
13201322
try {
1321-
List<PublicKey> result = apiInstance.userCurrentListKeys();
1323+
List<PublicKey> result = apiInstance.userCurrentListKeys(fingerprint);
13221324
System.out.println(result);
13231325
} catch (ApiException e) {
13241326
System.err.println("Exception when calling UserApi#userCurrentListKeys");
@@ -1327,7 +1329,10 @@ try {
13271329
```
13281330

13291331
### Parameters
1330-
This endpoint does not need any parameter.
1332+
1333+
Name | Type | Description | Notes
1334+
------------- | ------------- | ------------- | -------------
1335+
**fingerprint** | **String**| fingerprint of the key | [optional]
13311336

13321337
### Return type
13331338

@@ -2301,6 +2306,88 @@ This endpoint does not need any parameter.
23012306

23022307
[AccessToken](../README.md#AccessToken), [AuthorizationHeaderToken](../README.md#AuthorizationHeaderToken), [BasicAuth](../README.md#BasicAuth), [SudoHeader](../README.md#SudoHeader), [SudoParam](../README.md#SudoParam), [Token](../README.md#Token)
23032308

2309+
### HTTP request headers
2310+
2311+
- **Content-Type**: application/json, text/plain
2312+
- **Accept**: application/json
2313+
2314+
<a name="userGetHeatmapData"></a>
2315+
# **userGetHeatmapData**
2316+
> List&lt;UserHeatmapData&gt; userGetHeatmapData(username)
2317+
2318+
Get a user&#39;s heatmap
2319+
2320+
### Example
2321+
```java
2322+
// Import classes:
2323+
//import io.gitea.ApiClient;
2324+
//import io.gitea.ApiException;
2325+
//import io.gitea.Configuration;
2326+
//import io.gitea.auth.*;
2327+
//import io.gitea.api.UserApi;
2328+
2329+
ApiClient defaultClient = Configuration.getDefaultApiClient();
2330+
2331+
// Configure API key authorization: AccessToken
2332+
ApiKeyAuth AccessToken = (ApiKeyAuth) defaultClient.getAuthentication("AccessToken");
2333+
AccessToken.setApiKey("YOUR API KEY");
2334+
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
2335+
//AccessToken.setApiKeyPrefix("Token");
2336+
2337+
// Configure API key authorization: AuthorizationHeaderToken
2338+
ApiKeyAuth AuthorizationHeaderToken = (ApiKeyAuth) defaultClient.getAuthentication("AuthorizationHeaderToken");
2339+
AuthorizationHeaderToken.setApiKey("YOUR API KEY");
2340+
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
2341+
//AuthorizationHeaderToken.setApiKeyPrefix("Token");
2342+
2343+
// Configure HTTP basic authorization: BasicAuth
2344+
HttpBasicAuth BasicAuth = (HttpBasicAuth) defaultClient.getAuthentication("BasicAuth");
2345+
BasicAuth.setUsername("YOUR USERNAME");
2346+
BasicAuth.setPassword("YOUR PASSWORD");
2347+
2348+
// Configure API key authorization: SudoHeader
2349+
ApiKeyAuth SudoHeader = (ApiKeyAuth) defaultClient.getAuthentication("SudoHeader");
2350+
SudoHeader.setApiKey("YOUR API KEY");
2351+
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
2352+
//SudoHeader.setApiKeyPrefix("Token");
2353+
2354+
// Configure API key authorization: SudoParam
2355+
ApiKeyAuth SudoParam = (ApiKeyAuth) defaultClient.getAuthentication("SudoParam");
2356+
SudoParam.setApiKey("YOUR API KEY");
2357+
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
2358+
//SudoParam.setApiKeyPrefix("Token");
2359+
2360+
// Configure API key authorization: Token
2361+
ApiKeyAuth Token = (ApiKeyAuth) defaultClient.getAuthentication("Token");
2362+
Token.setApiKey("YOUR API KEY");
2363+
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
2364+
//Token.setApiKeyPrefix("Token");
2365+
2366+
UserApi apiInstance = new UserApi();
2367+
String username = "username_example"; // String | username of user to get
2368+
try {
2369+
List<UserHeatmapData> result = apiInstance.userGetHeatmapData(username);
2370+
System.out.println(result);
2371+
} catch (ApiException e) {
2372+
System.err.println("Exception when calling UserApi#userGetHeatmapData");
2373+
e.printStackTrace();
2374+
}
2375+
```
2376+
2377+
### Parameters
2378+
2379+
Name | Type | Description | Notes
2380+
------------- | ------------- | ------------- | -------------
2381+
**username** | **String**| username of user to get |
2382+
2383+
### Return type
2384+
2385+
[**List&lt;UserHeatmapData&gt;**](UserHeatmapData.md)
2386+
2387+
### Authorization
2388+
2389+
[AccessToken](../README.md#AccessToken), [AuthorizationHeaderToken](../README.md#AuthorizationHeaderToken), [BasicAuth](../README.md#BasicAuth), [SudoHeader](../README.md#SudoHeader), [SudoParam](../README.md#SudoParam), [Token](../README.md#Token)
2390+
23042391
### HTTP request headers
23052392

23062393
- **Content-Type**: application/json, text/plain
@@ -2714,7 +2801,7 @@ Name | Type | Description | Notes
27142801

27152802
<a name="userListKeys"></a>
27162803
# **userListKeys**
2717-
> List&lt;PublicKey&gt; userListKeys(username)
2804+
> List&lt;PublicKey&gt; userListKeys(username, fingerprint)
27182805
27192806
List the given user&#39;s public keys
27202807

@@ -2766,8 +2853,9 @@ Token.setApiKey("YOUR API KEY");
27662853

27672854
UserApi apiInstance = new UserApi();
27682855
String username = "username_example"; // String | username of user
2856+
String fingerprint = "fingerprint_example"; // String | fingerprint of the key
27692857
try {
2770-
List<PublicKey> result = apiInstance.userListKeys(username);
2858+
List<PublicKey> result = apiInstance.userListKeys(username, fingerprint);
27712859
System.out.println(result);
27722860
} catch (ApiException e) {
27732861
System.err.println("Exception when calling UserApi#userListKeys");
@@ -2780,6 +2868,7 @@ try {
27802868
Name | Type | Description | Notes
27812869
------------- | ------------- | ------------- | -------------
27822870
**username** | **String**| username of user |
2871+
**fingerprint** | **String**| fingerprint of the key | [optional]
27832872

27842873
### Return type
27852874

docs/UserHeatmapData.md

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
2+
# UserHeatmapData
3+
4+
## Properties
5+
Name | Type | Description | Notes
6+
------------ | ------------- | ------------- | -------------
7+
**contributions** | **Long** | | [optional]
8+
**timestamp** | **Integer** | | [optional]
9+
10+
11+

pom.xml

+3-4
Original file line numberDiff line numberDiff line change
@@ -54,17 +54,16 @@
5454
<plugin>
5555
<groupId>org.apache.maven.plugins</groupId>
5656
<artifactId>maven-surefire-plugin</artifactId>
57-
<version>2.12</version>
57+
<version>2.22.0</version>
5858
<configuration>
5959
<systemProperties>
6060
<property>
6161
<name>loggerPath</name>
6262
<value>conf/log4j.properties</value>
6363
</property>
6464
</systemProperties>
65-
<argLine>-Xms512m -Xmx1500m</argLine>
66-
<parallel>methods</parallel>
67-
<forkMode>pertest</forkMode>
65+
<argLine>-Xms512m -Xmx1500m --illegal-access=permit</argLine>
66+
<forkCount>0</forkCount>
6867
</configuration>
6968
</plugin>
7069
<plugin>

src/main/java/io/gitea/ApiException.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
import java.util.Map;
1717
import java.util.List;
1818

19-
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-10-20T18:39:27.321+01:00")
19+
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-11-02T17:53:11.028Z")
2020
public class ApiException extends Exception {
2121
private int code = 0;
2222
private Map<String, List<String>> responseHeaders = null;

src/main/java/io/gitea/Configuration.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313

1414
package io.gitea;
1515

16-
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-10-20T18:39:27.321+01:00")
16+
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-11-02T17:53:11.028Z")
1717
public class Configuration {
1818
private static ApiClient defaultApiClient = new ApiClient();
1919

src/main/java/io/gitea/Pair.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313

1414
package io.gitea;
1515

16-
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-10-20T18:39:27.321+01:00")
16+
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-11-02T17:53:11.028Z")
1717
public class Pair {
1818
private String name = "";
1919
private String value = "";

src/main/java/io/gitea/StringUtil.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313

1414
package io.gitea;
1515

16-
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-10-20T18:39:27.321+01:00")
16+
@javax.annotation.Generated(value = "io.swagger.codegen.languages.JavaClientCodegen", date = "2018-11-02T17:53:11.028Z")
1717
public class StringUtil {
1818
/**
1919
* Check if the given array contains the given value (with case-insensitive comparison).

src/main/java/io/gitea/api/RepositoryApi.java

+21-9
Original file line numberDiff line numberDiff line change
@@ -5121,12 +5121,14 @@ public void onRequestProgress(long bytesWritten, long contentLength, boolean don
51215121
* Build call for repoListKeys
51225122
* @param owner owner of the repo (required)
51235123
* @param repo name of the repo (required)
5124+
* @param keyId the key_id to search for (optional)
5125+
* @param fingerprint fingerprint of the key (optional)
51245126
* @param progressListener Progress listener
51255127
* @param progressRequestListener Progress request listener
51265128
* @return Call to execute
51275129
* @throws ApiException If fail to serialize the request body object
51285130
*/
5129-
public com.squareup.okhttp.Call repoListKeysCall(String owner, String repo, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
5131+
public com.squareup.okhttp.Call repoListKeysCall(String owner, String repo, Integer keyId, String fingerprint, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
51305132
Object localVarPostBody = null;
51315133

51325134
// create path and map variables
@@ -5136,6 +5138,10 @@ public com.squareup.okhttp.Call repoListKeysCall(String owner, String repo, fina
51365138

51375139
List<Pair> localVarQueryParams = new ArrayList<Pair>();
51385140
List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
5141+
if (keyId != null)
5142+
localVarQueryParams.addAll(apiClient.parameterToPair("key_id", keyId));
5143+
if (fingerprint != null)
5144+
localVarQueryParams.addAll(apiClient.parameterToPair("fingerprint", fingerprint));
51395145

51405146
Map<String, String> localVarHeaderParams = new HashMap<String, String>();
51415147

@@ -5170,7 +5176,7 @@ public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Ch
51705176
}
51715177

51725178
@SuppressWarnings("rawtypes")
5173-
private com.squareup.okhttp.Call repoListKeysValidateBeforeCall(String owner, String repo, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
5179+
private com.squareup.okhttp.Call repoListKeysValidateBeforeCall(String owner, String repo, Integer keyId, String fingerprint, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException {
51745180

51755181
// verify the required parameter 'owner' is set
51765182
if (owner == null) {
@@ -5183,7 +5189,7 @@ private com.squareup.okhttp.Call repoListKeysValidateBeforeCall(String owner, St
51835189
}
51845190

51855191

5186-
com.squareup.okhttp.Call call = repoListKeysCall(owner, repo, progressListener, progressRequestListener);
5192+
com.squareup.okhttp.Call call = repoListKeysCall(owner, repo, keyId, fingerprint, progressListener, progressRequestListener);
51875193
return call;
51885194

51895195
}
@@ -5193,11 +5199,13 @@ private com.squareup.okhttp.Call repoListKeysValidateBeforeCall(String owner, St
51935199
*
51945200
* @param owner owner of the repo (required)
51955201
* @param repo name of the repo (required)
5202+
* @param keyId the key_id to search for (optional)
5203+
* @param fingerprint fingerprint of the key (optional)
51965204
* @return List&lt;DeployKey&gt;
51975205
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
51985206
*/
5199-
public List<DeployKey> repoListKeys(String owner, String repo) throws ApiException {
5200-
ApiResponse<List<DeployKey>> resp = repoListKeysWithHttpInfo(owner, repo);
5207+
public List<DeployKey> repoListKeys(String owner, String repo, Integer keyId, String fingerprint) throws ApiException {
5208+
ApiResponse<List<DeployKey>> resp = repoListKeysWithHttpInfo(owner, repo, keyId, fingerprint);
52015209
return resp.getData();
52025210
}
52035211

@@ -5206,11 +5214,13 @@ public List<DeployKey> repoListKeys(String owner, String repo) throws ApiExcepti
52065214
*
52075215
* @param owner owner of the repo (required)
52085216
* @param repo name of the repo (required)
5217+
* @param keyId the key_id to search for (optional)
5218+
* @param fingerprint fingerprint of the key (optional)
52095219
* @return ApiResponse&lt;List&lt;DeployKey&gt;&gt;
52105220
* @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
52115221
*/
5212-
public ApiResponse<List<DeployKey>> repoListKeysWithHttpInfo(String owner, String repo) throws ApiException {
5213-
com.squareup.okhttp.Call call = repoListKeysValidateBeforeCall(owner, repo, null, null);
5222+
public ApiResponse<List<DeployKey>> repoListKeysWithHttpInfo(String owner, String repo, Integer keyId, String fingerprint) throws ApiException {
5223+
com.squareup.okhttp.Call call = repoListKeysValidateBeforeCall(owner, repo, keyId, fingerprint, null, null);
52145224
Type localVarReturnType = new TypeToken<List<DeployKey>>(){}.getType();
52155225
return apiClient.execute(call, localVarReturnType);
52165226
}
@@ -5220,11 +5230,13 @@ public ApiResponse<List<DeployKey>> repoListKeysWithHttpInfo(String owner, Strin
52205230
*
52215231
* @param owner owner of the repo (required)
52225232
* @param repo name of the repo (required)
5233+
* @param keyId the key_id to search for (optional)
5234+
* @param fingerprint fingerprint of the key (optional)
52235235
* @param callback The callback to be executed when the API call finishes
52245236
* @return The request call
52255237
* @throws ApiException If fail to process the API call, e.g. serializing the request body object
52265238
*/
5227-
public com.squareup.okhttp.Call repoListKeysAsync(String owner, String repo, final ApiCallback<List<DeployKey>> callback) throws ApiException {
5239+
public com.squareup.okhttp.Call repoListKeysAsync(String owner, String repo, Integer keyId, String fingerprint, final ApiCallback<List<DeployKey>> callback) throws ApiException {
52285240

52295241
ProgressResponseBody.ProgressListener progressListener = null;
52305242
ProgressRequestBody.ProgressRequestListener progressRequestListener = null;
@@ -5245,7 +5257,7 @@ public void onRequestProgress(long bytesWritten, long contentLength, boolean don
52455257
};
52465258
}
52475259

5248-
com.squareup.okhttp.Call call = repoListKeysValidateBeforeCall(owner, repo, progressListener, progressRequestListener);
5260+
com.squareup.okhttp.Call call = repoListKeysValidateBeforeCall(owner, repo, keyId, fingerprint, progressListener, progressRequestListener);
52495261
Type localVarReturnType = new TypeToken<List<DeployKey>>(){}.getType();
52505262
apiClient.executeAsync(call, localVarReturnType, callback);
52515263
return call;

0 commit comments

Comments
 (0)