github.com/treeverse/lakefs@v1.24.1-0.20240520134607-95648127bfb0/clients/java-legacy/docs/ActionsApi.md (about)

     1  # ActionsApi
     2  
     3  All URIs are relative to *http://localhost/api/v1*
     4  
     5  Method | HTTP request | Description
     6  ------------- | ------------- | -------------
     7  [**getRun**](ActionsApi.md#getRun) | **GET** /repositories/{repository}/actions/runs/{run_id} | get a run
     8  [**getRunHookOutput**](ActionsApi.md#getRunHookOutput) | **GET** /repositories/{repository}/actions/runs/{run_id}/hooks/{hook_run_id}/output | get run hook output
     9  [**listRepositoryRuns**](ActionsApi.md#listRepositoryRuns) | **GET** /repositories/{repository}/actions/runs | list runs
    10  [**listRunHooks**](ActionsApi.md#listRunHooks) | **GET** /repositories/{repository}/actions/runs/{run_id}/hooks | list run hooks
    11  
    12  
    13  <a name="getRun"></a>
    14  # **getRun**
    15  > ActionRun getRun(repository, runId)
    16  
    17  get a run
    18  
    19  ### Example
    20  ```java
    21  // Import classes:
    22  import io.lakefs.clients.api.ApiClient;
    23  import io.lakefs.clients.api.ApiException;
    24  import io.lakefs.clients.api.Configuration;
    25  import io.lakefs.clients.api.auth.*;
    26  import io.lakefs.clients.api.models.*;
    27  import io.lakefs.clients.api.ActionsApi;
    28  
    29  public class Example {
    30    public static void main(String[] args) {
    31      ApiClient defaultClient = Configuration.getDefaultApiClient();
    32      defaultClient.setBasePath("http://localhost/api/v1");
    33      
    34      // Configure HTTP basic authorization: basic_auth
    35      HttpBasicAuth basic_auth = (HttpBasicAuth) defaultClient.getAuthentication("basic_auth");
    36      basic_auth.setUsername("YOUR USERNAME");
    37      basic_auth.setPassword("YOUR PASSWORD");
    38  
    39      // Configure API key authorization: cookie_auth
    40      ApiKeyAuth cookie_auth = (ApiKeyAuth) defaultClient.getAuthentication("cookie_auth");
    41      cookie_auth.setApiKey("YOUR API KEY");
    42      // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    43      //cookie_auth.setApiKeyPrefix("Token");
    44  
    45      // Configure HTTP bearer authorization: jwt_token
    46      HttpBearerAuth jwt_token = (HttpBearerAuth) defaultClient.getAuthentication("jwt_token");
    47      jwt_token.setBearerToken("BEARER TOKEN");
    48  
    49      // Configure API key authorization: oidc_auth
    50      ApiKeyAuth oidc_auth = (ApiKeyAuth) defaultClient.getAuthentication("oidc_auth");
    51      oidc_auth.setApiKey("YOUR API KEY");
    52      // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    53      //oidc_auth.setApiKeyPrefix("Token");
    54  
    55      // Configure API key authorization: saml_auth
    56      ApiKeyAuth saml_auth = (ApiKeyAuth) defaultClient.getAuthentication("saml_auth");
    57      saml_auth.setApiKey("YOUR API KEY");
    58      // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
    59      //saml_auth.setApiKeyPrefix("Token");
    60  
    61      ActionsApi apiInstance = new ActionsApi(defaultClient);
    62      String repository = "repository_example"; // String | 
    63      String runId = "runId_example"; // String | 
    64      try {
    65        ActionRun result = apiInstance.getRun(repository, runId);
    66        System.out.println(result);
    67      } catch (ApiException e) {
    68        System.err.println("Exception when calling ActionsApi#getRun");
    69        System.err.println("Status code: " + e.getCode());
    70        System.err.println("Reason: " + e.getResponseBody());
    71        System.err.println("Response headers: " + e.getResponseHeaders());
    72        e.printStackTrace();
    73      }
    74    }
    75  }
    76  ```
    77  
    78  ### Parameters
    79  
    80  Name | Type | Description  | Notes
    81  ------------- | ------------- | ------------- | -------------
    82   **repository** | **String**|  |
    83   **runId** | **String**|  |
    84  
    85  ### Return type
    86  
    87  [**ActionRun**](ActionRun.md)
    88  
    89  ### Authorization
    90  
    91  [basic_auth](../README.md#basic_auth), [cookie_auth](../README.md#cookie_auth), [jwt_token](../README.md#jwt_token), [oidc_auth](../README.md#oidc_auth), [saml_auth](../README.md#saml_auth)
    92  
    93  ### HTTP request headers
    94  
    95   - **Content-Type**: Not defined
    96   - **Accept**: application/json
    97  
    98  ### HTTP response details
    99  | Status code | Description | Response headers |
   100  |-------------|-------------|------------------|
   101  **200** | action run result |  -  |
   102  **401** | Unauthorized |  -  |
   103  **404** | Resource Not Found |  -  |
   104  **420** | too many requests |  -  |
   105  **0** | Internal Server Error |  -  |
   106  
   107  <a name="getRunHookOutput"></a>
   108  # **getRunHookOutput**
   109  > File getRunHookOutput(repository, runId, hookRunId)
   110  
   111  get run hook output
   112  
   113  ### Example
   114  ```java
   115  // Import classes:
   116  import io.lakefs.clients.api.ApiClient;
   117  import io.lakefs.clients.api.ApiException;
   118  import io.lakefs.clients.api.Configuration;
   119  import io.lakefs.clients.api.auth.*;
   120  import io.lakefs.clients.api.models.*;
   121  import io.lakefs.clients.api.ActionsApi;
   122  
   123  public class Example {
   124    public static void main(String[] args) {
   125      ApiClient defaultClient = Configuration.getDefaultApiClient();
   126      defaultClient.setBasePath("http://localhost/api/v1");
   127      
   128      // Configure HTTP basic authorization: basic_auth
   129      HttpBasicAuth basic_auth = (HttpBasicAuth) defaultClient.getAuthentication("basic_auth");
   130      basic_auth.setUsername("YOUR USERNAME");
   131      basic_auth.setPassword("YOUR PASSWORD");
   132  
   133      // Configure API key authorization: cookie_auth
   134      ApiKeyAuth cookie_auth = (ApiKeyAuth) defaultClient.getAuthentication("cookie_auth");
   135      cookie_auth.setApiKey("YOUR API KEY");
   136      // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
   137      //cookie_auth.setApiKeyPrefix("Token");
   138  
   139      // Configure HTTP bearer authorization: jwt_token
   140      HttpBearerAuth jwt_token = (HttpBearerAuth) defaultClient.getAuthentication("jwt_token");
   141      jwt_token.setBearerToken("BEARER TOKEN");
   142  
   143      // Configure API key authorization: oidc_auth
   144      ApiKeyAuth oidc_auth = (ApiKeyAuth) defaultClient.getAuthentication("oidc_auth");
   145      oidc_auth.setApiKey("YOUR API KEY");
   146      // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
   147      //oidc_auth.setApiKeyPrefix("Token");
   148  
   149      // Configure API key authorization: saml_auth
   150      ApiKeyAuth saml_auth = (ApiKeyAuth) defaultClient.getAuthentication("saml_auth");
   151      saml_auth.setApiKey("YOUR API KEY");
   152      // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
   153      //saml_auth.setApiKeyPrefix("Token");
   154  
   155      ActionsApi apiInstance = new ActionsApi(defaultClient);
   156      String repository = "repository_example"; // String | 
   157      String runId = "runId_example"; // String | 
   158      String hookRunId = "hookRunId_example"; // String | 
   159      try {
   160        File result = apiInstance.getRunHookOutput(repository, runId, hookRunId);
   161        System.out.println(result);
   162      } catch (ApiException e) {
   163        System.err.println("Exception when calling ActionsApi#getRunHookOutput");
   164        System.err.println("Status code: " + e.getCode());
   165        System.err.println("Reason: " + e.getResponseBody());
   166        System.err.println("Response headers: " + e.getResponseHeaders());
   167        e.printStackTrace();
   168      }
   169    }
   170  }
   171  ```
   172  
   173  ### Parameters
   174  
   175  Name | Type | Description  | Notes
   176  ------------- | ------------- | ------------- | -------------
   177   **repository** | **String**|  |
   178   **runId** | **String**|  |
   179   **hookRunId** | **String**|  |
   180  
   181  ### Return type
   182  
   183  [**File**](File.md)
   184  
   185  ### Authorization
   186  
   187  [basic_auth](../README.md#basic_auth), [cookie_auth](../README.md#cookie_auth), [jwt_token](../README.md#jwt_token), [oidc_auth](../README.md#oidc_auth), [saml_auth](../README.md#saml_auth)
   188  
   189  ### HTTP request headers
   190  
   191   - **Content-Type**: Not defined
   192   - **Accept**: application/octet-stream, application/json
   193  
   194  ### HTTP response details
   195  | Status code | Description | Response headers |
   196  |-------------|-------------|------------------|
   197  **200** | run hook output |  -  |
   198  **401** | Unauthorized |  -  |
   199  **404** | Resource Not Found |  -  |
   200  **420** | too many requests |  -  |
   201  **0** | Internal Server Error |  -  |
   202  
   203  <a name="listRepositoryRuns"></a>
   204  # **listRepositoryRuns**
   205  > ActionRunList listRepositoryRuns(repository, after, amount, branch, commit)
   206  
   207  list runs
   208  
   209  ### Example
   210  ```java
   211  // Import classes:
   212  import io.lakefs.clients.api.ApiClient;
   213  import io.lakefs.clients.api.ApiException;
   214  import io.lakefs.clients.api.Configuration;
   215  import io.lakefs.clients.api.auth.*;
   216  import io.lakefs.clients.api.models.*;
   217  import io.lakefs.clients.api.ActionsApi;
   218  
   219  public class Example {
   220    public static void main(String[] args) {
   221      ApiClient defaultClient = Configuration.getDefaultApiClient();
   222      defaultClient.setBasePath("http://localhost/api/v1");
   223      
   224      // Configure HTTP basic authorization: basic_auth
   225      HttpBasicAuth basic_auth = (HttpBasicAuth) defaultClient.getAuthentication("basic_auth");
   226      basic_auth.setUsername("YOUR USERNAME");
   227      basic_auth.setPassword("YOUR PASSWORD");
   228  
   229      // Configure API key authorization: cookie_auth
   230      ApiKeyAuth cookie_auth = (ApiKeyAuth) defaultClient.getAuthentication("cookie_auth");
   231      cookie_auth.setApiKey("YOUR API KEY");
   232      // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
   233      //cookie_auth.setApiKeyPrefix("Token");
   234  
   235      // Configure HTTP bearer authorization: jwt_token
   236      HttpBearerAuth jwt_token = (HttpBearerAuth) defaultClient.getAuthentication("jwt_token");
   237      jwt_token.setBearerToken("BEARER TOKEN");
   238  
   239      // Configure API key authorization: oidc_auth
   240      ApiKeyAuth oidc_auth = (ApiKeyAuth) defaultClient.getAuthentication("oidc_auth");
   241      oidc_auth.setApiKey("YOUR API KEY");
   242      // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
   243      //oidc_auth.setApiKeyPrefix("Token");
   244  
   245      // Configure API key authorization: saml_auth
   246      ApiKeyAuth saml_auth = (ApiKeyAuth) defaultClient.getAuthentication("saml_auth");
   247      saml_auth.setApiKey("YOUR API KEY");
   248      // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
   249      //saml_auth.setApiKeyPrefix("Token");
   250  
   251      ActionsApi apiInstance = new ActionsApi(defaultClient);
   252      String repository = "repository_example"; // String | 
   253      String after = "after_example"; // String | return items after this value
   254      Integer amount = 100; // Integer | how many items to return
   255      String branch = "branch_example"; // String | 
   256      String commit = "commit_example"; // String | 
   257      try {
   258        ActionRunList result = apiInstance.listRepositoryRuns(repository, after, amount, branch, commit);
   259        System.out.println(result);
   260      } catch (ApiException e) {
   261        System.err.println("Exception when calling ActionsApi#listRepositoryRuns");
   262        System.err.println("Status code: " + e.getCode());
   263        System.err.println("Reason: " + e.getResponseBody());
   264        System.err.println("Response headers: " + e.getResponseHeaders());
   265        e.printStackTrace();
   266      }
   267    }
   268  }
   269  ```
   270  
   271  ### Parameters
   272  
   273  Name | Type | Description  | Notes
   274  ------------- | ------------- | ------------- | -------------
   275   **repository** | **String**|  |
   276   **after** | **String**| return items after this value | [optional]
   277   **amount** | **Integer**| how many items to return | [optional] [default to 100]
   278   **branch** | **String**|  | [optional]
   279   **commit** | **String**|  | [optional]
   280  
   281  ### Return type
   282  
   283  [**ActionRunList**](ActionRunList.md)
   284  
   285  ### Authorization
   286  
   287  [basic_auth](../README.md#basic_auth), [cookie_auth](../README.md#cookie_auth), [jwt_token](../README.md#jwt_token), [oidc_auth](../README.md#oidc_auth), [saml_auth](../README.md#saml_auth)
   288  
   289  ### HTTP request headers
   290  
   291   - **Content-Type**: Not defined
   292   - **Accept**: application/json
   293  
   294  ### HTTP response details
   295  | Status code | Description | Response headers |
   296  |-------------|-------------|------------------|
   297  **200** | list action runs |  -  |
   298  **401** | Unauthorized |  -  |
   299  **404** | Resource Not Found |  -  |
   300  **420** | too many requests |  -  |
   301  **0** | Internal Server Error |  -  |
   302  
   303  <a name="listRunHooks"></a>
   304  # **listRunHooks**
   305  > HookRunList listRunHooks(repository, runId, after, amount)
   306  
   307  list run hooks
   308  
   309  ### Example
   310  ```java
   311  // Import classes:
   312  import io.lakefs.clients.api.ApiClient;
   313  import io.lakefs.clients.api.ApiException;
   314  import io.lakefs.clients.api.Configuration;
   315  import io.lakefs.clients.api.auth.*;
   316  import io.lakefs.clients.api.models.*;
   317  import io.lakefs.clients.api.ActionsApi;
   318  
   319  public class Example {
   320    public static void main(String[] args) {
   321      ApiClient defaultClient = Configuration.getDefaultApiClient();
   322      defaultClient.setBasePath("http://localhost/api/v1");
   323      
   324      // Configure HTTP basic authorization: basic_auth
   325      HttpBasicAuth basic_auth = (HttpBasicAuth) defaultClient.getAuthentication("basic_auth");
   326      basic_auth.setUsername("YOUR USERNAME");
   327      basic_auth.setPassword("YOUR PASSWORD");
   328  
   329      // Configure API key authorization: cookie_auth
   330      ApiKeyAuth cookie_auth = (ApiKeyAuth) defaultClient.getAuthentication("cookie_auth");
   331      cookie_auth.setApiKey("YOUR API KEY");
   332      // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
   333      //cookie_auth.setApiKeyPrefix("Token");
   334  
   335      // Configure HTTP bearer authorization: jwt_token
   336      HttpBearerAuth jwt_token = (HttpBearerAuth) defaultClient.getAuthentication("jwt_token");
   337      jwt_token.setBearerToken("BEARER TOKEN");
   338  
   339      // Configure API key authorization: oidc_auth
   340      ApiKeyAuth oidc_auth = (ApiKeyAuth) defaultClient.getAuthentication("oidc_auth");
   341      oidc_auth.setApiKey("YOUR API KEY");
   342      // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
   343      //oidc_auth.setApiKeyPrefix("Token");
   344  
   345      // Configure API key authorization: saml_auth
   346      ApiKeyAuth saml_auth = (ApiKeyAuth) defaultClient.getAuthentication("saml_auth");
   347      saml_auth.setApiKey("YOUR API KEY");
   348      // Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
   349      //saml_auth.setApiKeyPrefix("Token");
   350  
   351      ActionsApi apiInstance = new ActionsApi(defaultClient);
   352      String repository = "repository_example"; // String | 
   353      String runId = "runId_example"; // String | 
   354      String after = "after_example"; // String | return items after this value
   355      Integer amount = 100; // Integer | how many items to return
   356      try {
   357        HookRunList result = apiInstance.listRunHooks(repository, runId, after, amount);
   358        System.out.println(result);
   359      } catch (ApiException e) {
   360        System.err.println("Exception when calling ActionsApi#listRunHooks");
   361        System.err.println("Status code: " + e.getCode());
   362        System.err.println("Reason: " + e.getResponseBody());
   363        System.err.println("Response headers: " + e.getResponseHeaders());
   364        e.printStackTrace();
   365      }
   366    }
   367  }
   368  ```
   369  
   370  ### Parameters
   371  
   372  Name | Type | Description  | Notes
   373  ------------- | ------------- | ------------- | -------------
   374   **repository** | **String**|  |
   375   **runId** | **String**|  |
   376   **after** | **String**| return items after this value | [optional]
   377   **amount** | **Integer**| how many items to return | [optional] [default to 100]
   378  
   379  ### Return type
   380  
   381  [**HookRunList**](HookRunList.md)
   382  
   383  ### Authorization
   384  
   385  [basic_auth](../README.md#basic_auth), [cookie_auth](../README.md#cookie_auth), [jwt_token](../README.md#jwt_token), [oidc_auth](../README.md#oidc_auth), [saml_auth](../README.md#saml_auth)
   386  
   387  ### HTTP request headers
   388  
   389   - **Content-Type**: Not defined
   390   - **Accept**: application/json
   391  
   392  ### HTTP response details
   393  | Status code | Description | Response headers |
   394  |-------------|-------------|------------------|
   395  **200** | list specific run hooks |  -  |
   396  **401** | Unauthorized |  -  |
   397  **404** | Resource Not Found |  -  |
   398  **420** | too many requests |  -  |
   399  **0** | Internal Server Error |  -  |
   400