github.com/treeverse/lakefs@v1.24.1-0.20240520134607-95648127bfb0/clients/python-legacy/docs/AuthApi.md (about) 1 # lakefs_client.AuthApi 2 3 All URIs are relative to *http://localhost/api/v1* 4 5 Method | HTTP request | Description 6 ------------- | ------------- | ------------- 7 [**add_group_membership**](AuthApi.md#add_group_membership) | **PUT** /auth/groups/{groupId}/members/{userId} | add group membership 8 [**attach_policy_to_group**](AuthApi.md#attach_policy_to_group) | **PUT** /auth/groups/{groupId}/policies/{policyId} | attach policy to group 9 [**attach_policy_to_user**](AuthApi.md#attach_policy_to_user) | **PUT** /auth/users/{userId}/policies/{policyId} | attach policy to user 10 [**create_credentials**](AuthApi.md#create_credentials) | **POST** /auth/users/{userId}/credentials | create credentials 11 [**create_group**](AuthApi.md#create_group) | **POST** /auth/groups | create group 12 [**create_policy**](AuthApi.md#create_policy) | **POST** /auth/policies | create policy 13 [**create_user**](AuthApi.md#create_user) | **POST** /auth/users | create user 14 [**create_user_external_principal**](AuthApi.md#create_user_external_principal) | **POST** /auth/users/{userId}/external/principals | attach external principal to user 15 [**delete_credentials**](AuthApi.md#delete_credentials) | **DELETE** /auth/users/{userId}/credentials/{accessKeyId} | delete credentials 16 [**delete_group**](AuthApi.md#delete_group) | **DELETE** /auth/groups/{groupId} | delete group 17 [**delete_group_membership**](AuthApi.md#delete_group_membership) | **DELETE** /auth/groups/{groupId}/members/{userId} | delete group membership 18 [**delete_policy**](AuthApi.md#delete_policy) | **DELETE** /auth/policies/{policyId} | delete policy 19 [**delete_user**](AuthApi.md#delete_user) | **DELETE** /auth/users/{userId} | delete user 20 [**delete_user_external_principal**](AuthApi.md#delete_user_external_principal) | **DELETE** /auth/users/{userId}/external/principals | delete external principal from user 21 [**detach_policy_from_group**](AuthApi.md#detach_policy_from_group) | **DELETE** /auth/groups/{groupId}/policies/{policyId} | detach policy from group 22 [**detach_policy_from_user**](AuthApi.md#detach_policy_from_user) | **DELETE** /auth/users/{userId}/policies/{policyId} | detach policy from user 23 [**external_principal_login**](AuthApi.md#external_principal_login) | **POST** /auth/external/principal/login | perform a login using an external authenticator 24 [**get_credentials**](AuthApi.md#get_credentials) | **GET** /auth/users/{userId}/credentials/{accessKeyId} | get credentials 25 [**get_current_user**](AuthApi.md#get_current_user) | **GET** /user | get current user 26 [**get_external_principal**](AuthApi.md#get_external_principal) | **GET** /auth/external/principals | describe external principal by id 27 [**get_group**](AuthApi.md#get_group) | **GET** /auth/groups/{groupId} | get group 28 [**get_group_acl**](AuthApi.md#get_group_acl) | **GET** /auth/groups/{groupId}/acl | get ACL of group 29 [**get_policy**](AuthApi.md#get_policy) | **GET** /auth/policies/{policyId} | get policy 30 [**get_user**](AuthApi.md#get_user) | **GET** /auth/users/{userId} | get user 31 [**list_group_members**](AuthApi.md#list_group_members) | **GET** /auth/groups/{groupId}/members | list group members 32 [**list_group_policies**](AuthApi.md#list_group_policies) | **GET** /auth/groups/{groupId}/policies | list group policies 33 [**list_groups**](AuthApi.md#list_groups) | **GET** /auth/groups | list groups 34 [**list_policies**](AuthApi.md#list_policies) | **GET** /auth/policies | list policies 35 [**list_user_credentials**](AuthApi.md#list_user_credentials) | **GET** /auth/users/{userId}/credentials | list user credentials 36 [**list_user_external_principals**](AuthApi.md#list_user_external_principals) | **GET** /auth/users/{userId}/external/principals/ls | list user external policies attached to a user 37 [**list_user_groups**](AuthApi.md#list_user_groups) | **GET** /auth/users/{userId}/groups | list user groups 38 [**list_user_policies**](AuthApi.md#list_user_policies) | **GET** /auth/users/{userId}/policies | list user policies 39 [**list_users**](AuthApi.md#list_users) | **GET** /auth/users | list users 40 [**login**](AuthApi.md#login) | **POST** /auth/login | perform a login 41 [**set_group_acl**](AuthApi.md#set_group_acl) | **POST** /auth/groups/{groupId}/acl | set ACL of group 42 [**update_policy**](AuthApi.md#update_policy) | **PUT** /auth/policies/{policyId} | update policy 43 44 45 # **add_group_membership** 46 > add_group_membership(group_id, user_id) 47 48 add group membership 49 50 ### Example 51 52 * Basic Authentication (basic_auth): 53 * Api Key Authentication (cookie_auth): 54 * Bearer (JWT) Authentication (jwt_token): 55 * Api Key Authentication (oidc_auth): 56 * Api Key Authentication (saml_auth): 57 58 ```python 59 import time 60 import lakefs_client 61 from lakefs_client.api import auth_api 62 from lakefs_client.model.error import Error 63 from pprint import pprint 64 # Defining the host is optional and defaults to http://localhost/api/v1 65 # See configuration.py for a list of all supported configuration parameters. 66 configuration = lakefs_client.Configuration( 67 host = "http://localhost/api/v1" 68 ) 69 70 # The client must configure the authentication and authorization parameters 71 # in accordance with the API server security policy. 72 # Examples for each auth method are provided below, use the example that 73 # satisfies your auth use case. 74 75 # Configure HTTP basic authorization: basic_auth 76 configuration = lakefs_client.Configuration( 77 username = 'YOUR_USERNAME', 78 password = 'YOUR_PASSWORD' 79 ) 80 81 # Configure API key authorization: cookie_auth 82 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 83 84 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 85 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 86 87 # Configure Bearer authorization (JWT): jwt_token 88 configuration = lakefs_client.Configuration( 89 access_token = 'YOUR_BEARER_TOKEN' 90 ) 91 92 # Configure API key authorization: oidc_auth 93 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 94 95 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 96 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 97 98 # Configure API key authorization: saml_auth 99 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 100 101 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 102 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 103 104 # Enter a context with an instance of the API client 105 with lakefs_client.ApiClient(configuration) as api_client: 106 # Create an instance of the API class 107 api_instance = auth_api.AuthApi(api_client) 108 group_id = "groupId_example" # str | 109 user_id = "userId_example" # str | 110 111 # example passing only required values which don't have defaults set 112 try: 113 # add group membership 114 api_instance.add_group_membership(group_id, user_id) 115 except lakefs_client.ApiException as e: 116 print("Exception when calling AuthApi->add_group_membership: %s\n" % e) 117 ``` 118 119 120 ### Parameters 121 122 Name | Type | Description | Notes 123 ------------- | ------------- | ------------- | ------------- 124 **group_id** | **str**| | 125 **user_id** | **str**| | 126 127 ### Return type 128 129 void (empty response body) 130 131 ### Authorization 132 133 [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) 134 135 ### HTTP request headers 136 137 - **Content-Type**: Not defined 138 - **Accept**: application/json 139 140 141 ### HTTP response details 142 143 | Status code | Description | Response headers | 144 |-------------|-------------|------------------| 145 **201** | membership added successfully | - | 146 **401** | Unauthorized | - | 147 **404** | Resource Not Found | - | 148 **420** | too many requests | - | 149 **0** | Internal Server Error | - | 150 151 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 152 153 # **attach_policy_to_group** 154 > attach_policy_to_group(group_id, policy_id) 155 156 attach policy to group 157 158 ### Example 159 160 * Basic Authentication (basic_auth): 161 * Api Key Authentication (cookie_auth): 162 * Bearer (JWT) Authentication (jwt_token): 163 * Api Key Authentication (oidc_auth): 164 * Api Key Authentication (saml_auth): 165 166 ```python 167 import time 168 import lakefs_client 169 from lakefs_client.api import auth_api 170 from lakefs_client.model.error import Error 171 from pprint import pprint 172 # Defining the host is optional and defaults to http://localhost/api/v1 173 # See configuration.py for a list of all supported configuration parameters. 174 configuration = lakefs_client.Configuration( 175 host = "http://localhost/api/v1" 176 ) 177 178 # The client must configure the authentication and authorization parameters 179 # in accordance with the API server security policy. 180 # Examples for each auth method are provided below, use the example that 181 # satisfies your auth use case. 182 183 # Configure HTTP basic authorization: basic_auth 184 configuration = lakefs_client.Configuration( 185 username = 'YOUR_USERNAME', 186 password = 'YOUR_PASSWORD' 187 ) 188 189 # Configure API key authorization: cookie_auth 190 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 191 192 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 193 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 194 195 # Configure Bearer authorization (JWT): jwt_token 196 configuration = lakefs_client.Configuration( 197 access_token = 'YOUR_BEARER_TOKEN' 198 ) 199 200 # Configure API key authorization: oidc_auth 201 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 202 203 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 204 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 205 206 # Configure API key authorization: saml_auth 207 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 208 209 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 210 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 211 212 # Enter a context with an instance of the API client 213 with lakefs_client.ApiClient(configuration) as api_client: 214 # Create an instance of the API class 215 api_instance = auth_api.AuthApi(api_client) 216 group_id = "groupId_example" # str | 217 policy_id = "policyId_example" # str | 218 219 # example passing only required values which don't have defaults set 220 try: 221 # attach policy to group 222 api_instance.attach_policy_to_group(group_id, policy_id) 223 except lakefs_client.ApiException as e: 224 print("Exception when calling AuthApi->attach_policy_to_group: %s\n" % e) 225 ``` 226 227 228 ### Parameters 229 230 Name | Type | Description | Notes 231 ------------- | ------------- | ------------- | ------------- 232 **group_id** | **str**| | 233 **policy_id** | **str**| | 234 235 ### Return type 236 237 void (empty response body) 238 239 ### Authorization 240 241 [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) 242 243 ### HTTP request headers 244 245 - **Content-Type**: Not defined 246 - **Accept**: application/json 247 248 249 ### HTTP response details 250 251 | Status code | Description | Response headers | 252 |-------------|-------------|------------------| 253 **201** | policy attached successfully | - | 254 **401** | Unauthorized | - | 255 **404** | Resource Not Found | - | 256 **420** | too many requests | - | 257 **0** | Internal Server Error | - | 258 259 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 260 261 # **attach_policy_to_user** 262 > attach_policy_to_user(user_id, policy_id) 263 264 attach policy to user 265 266 ### Example 267 268 * Basic Authentication (basic_auth): 269 * Api Key Authentication (cookie_auth): 270 * Bearer (JWT) Authentication (jwt_token): 271 * Api Key Authentication (oidc_auth): 272 * Api Key Authentication (saml_auth): 273 274 ```python 275 import time 276 import lakefs_client 277 from lakefs_client.api import auth_api 278 from lakefs_client.model.error import Error 279 from pprint import pprint 280 # Defining the host is optional and defaults to http://localhost/api/v1 281 # See configuration.py for a list of all supported configuration parameters. 282 configuration = lakefs_client.Configuration( 283 host = "http://localhost/api/v1" 284 ) 285 286 # The client must configure the authentication and authorization parameters 287 # in accordance with the API server security policy. 288 # Examples for each auth method are provided below, use the example that 289 # satisfies your auth use case. 290 291 # Configure HTTP basic authorization: basic_auth 292 configuration = lakefs_client.Configuration( 293 username = 'YOUR_USERNAME', 294 password = 'YOUR_PASSWORD' 295 ) 296 297 # Configure API key authorization: cookie_auth 298 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 299 300 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 301 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 302 303 # Configure Bearer authorization (JWT): jwt_token 304 configuration = lakefs_client.Configuration( 305 access_token = 'YOUR_BEARER_TOKEN' 306 ) 307 308 # Configure API key authorization: oidc_auth 309 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 310 311 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 312 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 313 314 # Configure API key authorization: saml_auth 315 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 316 317 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 318 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 319 320 # Enter a context with an instance of the API client 321 with lakefs_client.ApiClient(configuration) as api_client: 322 # Create an instance of the API class 323 api_instance = auth_api.AuthApi(api_client) 324 user_id = "userId_example" # str | 325 policy_id = "policyId_example" # str | 326 327 # example passing only required values which don't have defaults set 328 try: 329 # attach policy to user 330 api_instance.attach_policy_to_user(user_id, policy_id) 331 except lakefs_client.ApiException as e: 332 print("Exception when calling AuthApi->attach_policy_to_user: %s\n" % e) 333 ``` 334 335 336 ### Parameters 337 338 Name | Type | Description | Notes 339 ------------- | ------------- | ------------- | ------------- 340 **user_id** | **str**| | 341 **policy_id** | **str**| | 342 343 ### Return type 344 345 void (empty response body) 346 347 ### Authorization 348 349 [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) 350 351 ### HTTP request headers 352 353 - **Content-Type**: Not defined 354 - **Accept**: application/json 355 356 357 ### HTTP response details 358 359 | Status code | Description | Response headers | 360 |-------------|-------------|------------------| 361 **201** | policy attached successfully | - | 362 **401** | Unauthorized | - | 363 **404** | Resource Not Found | - | 364 **420** | too many requests | - | 365 **0** | Internal Server Error | - | 366 367 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 368 369 # **create_credentials** 370 > CredentialsWithSecret create_credentials(user_id) 371 372 create credentials 373 374 ### Example 375 376 * Basic Authentication (basic_auth): 377 * Api Key Authentication (cookie_auth): 378 * Bearer (JWT) Authentication (jwt_token): 379 * Api Key Authentication (oidc_auth): 380 * Api Key Authentication (saml_auth): 381 382 ```python 383 import time 384 import lakefs_client 385 from lakefs_client.api import auth_api 386 from lakefs_client.model.credentials_with_secret import CredentialsWithSecret 387 from lakefs_client.model.error import Error 388 from pprint import pprint 389 # Defining the host is optional and defaults to http://localhost/api/v1 390 # See configuration.py for a list of all supported configuration parameters. 391 configuration = lakefs_client.Configuration( 392 host = "http://localhost/api/v1" 393 ) 394 395 # The client must configure the authentication and authorization parameters 396 # in accordance with the API server security policy. 397 # Examples for each auth method are provided below, use the example that 398 # satisfies your auth use case. 399 400 # Configure HTTP basic authorization: basic_auth 401 configuration = lakefs_client.Configuration( 402 username = 'YOUR_USERNAME', 403 password = 'YOUR_PASSWORD' 404 ) 405 406 # Configure API key authorization: cookie_auth 407 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 408 409 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 410 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 411 412 # Configure Bearer authorization (JWT): jwt_token 413 configuration = lakefs_client.Configuration( 414 access_token = 'YOUR_BEARER_TOKEN' 415 ) 416 417 # Configure API key authorization: oidc_auth 418 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 419 420 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 421 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 422 423 # Configure API key authorization: saml_auth 424 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 425 426 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 427 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 428 429 # Enter a context with an instance of the API client 430 with lakefs_client.ApiClient(configuration) as api_client: 431 # Create an instance of the API class 432 api_instance = auth_api.AuthApi(api_client) 433 user_id = "userId_example" # str | 434 435 # example passing only required values which don't have defaults set 436 try: 437 # create credentials 438 api_response = api_instance.create_credentials(user_id) 439 pprint(api_response) 440 except lakefs_client.ApiException as e: 441 print("Exception when calling AuthApi->create_credentials: %s\n" % e) 442 ``` 443 444 445 ### Parameters 446 447 Name | Type | Description | Notes 448 ------------- | ------------- | ------------- | ------------- 449 **user_id** | **str**| | 450 451 ### Return type 452 453 [**CredentialsWithSecret**](CredentialsWithSecret.md) 454 455 ### Authorization 456 457 [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) 458 459 ### HTTP request headers 460 461 - **Content-Type**: Not defined 462 - **Accept**: application/json 463 464 465 ### HTTP response details 466 467 | Status code | Description | Response headers | 468 |-------------|-------------|------------------| 469 **201** | credentials | - | 470 **401** | Unauthorized | - | 471 **404** | Resource Not Found | - | 472 **420** | too many requests | - | 473 **0** | Internal Server Error | - | 474 475 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 476 477 # **create_group** 478 > Group create_group() 479 480 create group 481 482 ### Example 483 484 * Basic Authentication (basic_auth): 485 * Api Key Authentication (cookie_auth): 486 * Bearer (JWT) Authentication (jwt_token): 487 * Api Key Authentication (oidc_auth): 488 * Api Key Authentication (saml_auth): 489 490 ```python 491 import time 492 import lakefs_client 493 from lakefs_client.api import auth_api 494 from lakefs_client.model.group_creation import GroupCreation 495 from lakefs_client.model.error import Error 496 from lakefs_client.model.group import Group 497 from pprint import pprint 498 # Defining the host is optional and defaults to http://localhost/api/v1 499 # See configuration.py for a list of all supported configuration parameters. 500 configuration = lakefs_client.Configuration( 501 host = "http://localhost/api/v1" 502 ) 503 504 # The client must configure the authentication and authorization parameters 505 # in accordance with the API server security policy. 506 # Examples for each auth method are provided below, use the example that 507 # satisfies your auth use case. 508 509 # Configure HTTP basic authorization: basic_auth 510 configuration = lakefs_client.Configuration( 511 username = 'YOUR_USERNAME', 512 password = 'YOUR_PASSWORD' 513 ) 514 515 # Configure API key authorization: cookie_auth 516 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 517 518 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 519 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 520 521 # Configure Bearer authorization (JWT): jwt_token 522 configuration = lakefs_client.Configuration( 523 access_token = 'YOUR_BEARER_TOKEN' 524 ) 525 526 # Configure API key authorization: oidc_auth 527 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 528 529 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 530 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 531 532 # Configure API key authorization: saml_auth 533 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 534 535 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 536 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 537 538 # Enter a context with an instance of the API client 539 with lakefs_client.ApiClient(configuration) as api_client: 540 # Create an instance of the API class 541 api_instance = auth_api.AuthApi(api_client) 542 group_creation = GroupCreation( 543 id="id_example", 544 ) # GroupCreation | (optional) 545 546 # example passing only required values which don't have defaults set 547 # and optional values 548 try: 549 # create group 550 api_response = api_instance.create_group(group_creation=group_creation) 551 pprint(api_response) 552 except lakefs_client.ApiException as e: 553 print("Exception when calling AuthApi->create_group: %s\n" % e) 554 ``` 555 556 557 ### Parameters 558 559 Name | Type | Description | Notes 560 ------------- | ------------- | ------------- | ------------- 561 **group_creation** | [**GroupCreation**](GroupCreation.md)| | [optional] 562 563 ### Return type 564 565 [**Group**](Group.md) 566 567 ### Authorization 568 569 [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) 570 571 ### HTTP request headers 572 573 - **Content-Type**: application/json 574 - **Accept**: application/json 575 576 577 ### HTTP response details 578 579 | Status code | Description | Response headers | 580 |-------------|-------------|------------------| 581 **201** | group | - | 582 **401** | Unauthorized | - | 583 **404** | Resource Not Found | - | 584 **420** | too many requests | - | 585 **0** | Internal Server Error | - | 586 587 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 588 589 # **create_policy** 590 > Policy create_policy(policy) 591 592 create policy 593 594 ### Example 595 596 * Basic Authentication (basic_auth): 597 * Api Key Authentication (cookie_auth): 598 * Bearer (JWT) Authentication (jwt_token): 599 * Api Key Authentication (oidc_auth): 600 * Api Key Authentication (saml_auth): 601 602 ```python 603 import time 604 import lakefs_client 605 from lakefs_client.api import auth_api 606 from lakefs_client.model.policy import Policy 607 from lakefs_client.model.error import Error 608 from pprint import pprint 609 # Defining the host is optional and defaults to http://localhost/api/v1 610 # See configuration.py for a list of all supported configuration parameters. 611 configuration = lakefs_client.Configuration( 612 host = "http://localhost/api/v1" 613 ) 614 615 # The client must configure the authentication and authorization parameters 616 # in accordance with the API server security policy. 617 # Examples for each auth method are provided below, use the example that 618 # satisfies your auth use case. 619 620 # Configure HTTP basic authorization: basic_auth 621 configuration = lakefs_client.Configuration( 622 username = 'YOUR_USERNAME', 623 password = 'YOUR_PASSWORD' 624 ) 625 626 # Configure API key authorization: cookie_auth 627 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 628 629 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 630 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 631 632 # Configure Bearer authorization (JWT): jwt_token 633 configuration = lakefs_client.Configuration( 634 access_token = 'YOUR_BEARER_TOKEN' 635 ) 636 637 # Configure API key authorization: oidc_auth 638 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 639 640 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 641 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 642 643 # Configure API key authorization: saml_auth 644 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 645 646 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 647 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 648 649 # Enter a context with an instance of the API client 650 with lakefs_client.ApiClient(configuration) as api_client: 651 # Create an instance of the API class 652 api_instance = auth_api.AuthApi(api_client) 653 policy = Policy( 654 id="id_example", 655 creation_date=1, 656 statement=[ 657 Statement( 658 effect="allow", 659 resource="resource_example", 660 action=[ 661 "action_example", 662 ], 663 ), 664 ], 665 ) # Policy | 666 667 # example passing only required values which don't have defaults set 668 try: 669 # create policy 670 api_response = api_instance.create_policy(policy) 671 pprint(api_response) 672 except lakefs_client.ApiException as e: 673 print("Exception when calling AuthApi->create_policy: %s\n" % e) 674 ``` 675 676 677 ### Parameters 678 679 Name | Type | Description | Notes 680 ------------- | ------------- | ------------- | ------------- 681 **policy** | [**Policy**](Policy.md)| | 682 683 ### Return type 684 685 [**Policy**](Policy.md) 686 687 ### Authorization 688 689 [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) 690 691 ### HTTP request headers 692 693 - **Content-Type**: application/json 694 - **Accept**: application/json 695 696 697 ### HTTP response details 698 699 | Status code | Description | Response headers | 700 |-------------|-------------|------------------| 701 **201** | policy | - | 702 **400** | Validation Error | - | 703 **401** | Unauthorized | - | 704 **409** | Resource Conflicts With Target | - | 705 **420** | too many requests | - | 706 **0** | Internal Server Error | - | 707 708 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 709 710 # **create_user** 711 > User create_user() 712 713 create user 714 715 ### Example 716 717 * Basic Authentication (basic_auth): 718 * Api Key Authentication (cookie_auth): 719 * Bearer (JWT) Authentication (jwt_token): 720 * Api Key Authentication (oidc_auth): 721 * Api Key Authentication (saml_auth): 722 723 ```python 724 import time 725 import lakefs_client 726 from lakefs_client.api import auth_api 727 from lakefs_client.model.error import Error 728 from lakefs_client.model.user import User 729 from lakefs_client.model.user_creation import UserCreation 730 from pprint import pprint 731 # Defining the host is optional and defaults to http://localhost/api/v1 732 # See configuration.py for a list of all supported configuration parameters. 733 configuration = lakefs_client.Configuration( 734 host = "http://localhost/api/v1" 735 ) 736 737 # The client must configure the authentication and authorization parameters 738 # in accordance with the API server security policy. 739 # Examples for each auth method are provided below, use the example that 740 # satisfies your auth use case. 741 742 # Configure HTTP basic authorization: basic_auth 743 configuration = lakefs_client.Configuration( 744 username = 'YOUR_USERNAME', 745 password = 'YOUR_PASSWORD' 746 ) 747 748 # Configure API key authorization: cookie_auth 749 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 750 751 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 752 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 753 754 # Configure Bearer authorization (JWT): jwt_token 755 configuration = lakefs_client.Configuration( 756 access_token = 'YOUR_BEARER_TOKEN' 757 ) 758 759 # Configure API key authorization: oidc_auth 760 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 761 762 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 763 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 764 765 # Configure API key authorization: saml_auth 766 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 767 768 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 769 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 770 771 # Enter a context with an instance of the API client 772 with lakefs_client.ApiClient(configuration) as api_client: 773 # Create an instance of the API class 774 api_instance = auth_api.AuthApi(api_client) 775 user_creation = UserCreation( 776 id="id_example", 777 invite_user=True, 778 ) # UserCreation | (optional) 779 780 # example passing only required values which don't have defaults set 781 # and optional values 782 try: 783 # create user 784 api_response = api_instance.create_user(user_creation=user_creation) 785 pprint(api_response) 786 except lakefs_client.ApiException as e: 787 print("Exception when calling AuthApi->create_user: %s\n" % e) 788 ``` 789 790 791 ### Parameters 792 793 Name | Type | Description | Notes 794 ------------- | ------------- | ------------- | ------------- 795 **user_creation** | [**UserCreation**](UserCreation.md)| | [optional] 796 797 ### Return type 798 799 [**User**](User.md) 800 801 ### Authorization 802 803 [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) 804 805 ### HTTP request headers 806 807 - **Content-Type**: application/json 808 - **Accept**: application/json 809 810 811 ### HTTP response details 812 813 | Status code | Description | Response headers | 814 |-------------|-------------|------------------| 815 **201** | user | - | 816 **400** | validation error | - | 817 **401** | Unauthorized | - | 818 **409** | Resource Conflicts With Target | - | 819 **420** | too many requests | - | 820 **0** | Internal Server Error | - | 821 822 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 823 824 # **create_user_external_principal** 825 > create_user_external_principal(user_id, principal_id) 826 827 attach external principal to user 828 829 ### Example 830 831 * Basic Authentication (basic_auth): 832 * Api Key Authentication (cookie_auth): 833 * Bearer (JWT) Authentication (jwt_token): 834 * Api Key Authentication (oidc_auth): 835 * Api Key Authentication (saml_auth): 836 837 ```python 838 import time 839 import lakefs_client 840 from lakefs_client.api import auth_api 841 from lakefs_client.model.error import Error 842 from lakefs_client.model.external_principal_creation import ExternalPrincipalCreation 843 from pprint import pprint 844 # Defining the host is optional and defaults to http://localhost/api/v1 845 # See configuration.py for a list of all supported configuration parameters. 846 configuration = lakefs_client.Configuration( 847 host = "http://localhost/api/v1" 848 ) 849 850 # The client must configure the authentication and authorization parameters 851 # in accordance with the API server security policy. 852 # Examples for each auth method are provided below, use the example that 853 # satisfies your auth use case. 854 855 # Configure HTTP basic authorization: basic_auth 856 configuration = lakefs_client.Configuration( 857 username = 'YOUR_USERNAME', 858 password = 'YOUR_PASSWORD' 859 ) 860 861 # Configure API key authorization: cookie_auth 862 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 863 864 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 865 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 866 867 # Configure Bearer authorization (JWT): jwt_token 868 configuration = lakefs_client.Configuration( 869 access_token = 'YOUR_BEARER_TOKEN' 870 ) 871 872 # Configure API key authorization: oidc_auth 873 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 874 875 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 876 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 877 878 # Configure API key authorization: saml_auth 879 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 880 881 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 882 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 883 884 # Enter a context with an instance of the API client 885 with lakefs_client.ApiClient(configuration) as api_client: 886 # Create an instance of the API class 887 api_instance = auth_api.AuthApi(api_client) 888 user_id = "userId_example" # str | 889 principal_id = "principalId_example" # str | 890 external_principal_creation = ExternalPrincipalCreation( 891 settings=[ 892 ExternalPrincipalSettings( 893 key="key_example", 894 ), 895 ], 896 ) # ExternalPrincipalCreation | (optional) 897 898 # example passing only required values which don't have defaults set 899 try: 900 # attach external principal to user 901 api_instance.create_user_external_principal(user_id, principal_id) 902 except lakefs_client.ApiException as e: 903 print("Exception when calling AuthApi->create_user_external_principal: %s\n" % e) 904 905 # example passing only required values which don't have defaults set 906 # and optional values 907 try: 908 # attach external principal to user 909 api_instance.create_user_external_principal(user_id, principal_id, external_principal_creation=external_principal_creation) 910 except lakefs_client.ApiException as e: 911 print("Exception when calling AuthApi->create_user_external_principal: %s\n" % e) 912 ``` 913 914 915 ### Parameters 916 917 Name | Type | Description | Notes 918 ------------- | ------------- | ------------- | ------------- 919 **user_id** | **str**| | 920 **principal_id** | **str**| | 921 **external_principal_creation** | [**ExternalPrincipalCreation**](ExternalPrincipalCreation.md)| | [optional] 922 923 ### Return type 924 925 void (empty response body) 926 927 ### Authorization 928 929 [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) 930 931 ### HTTP request headers 932 933 - **Content-Type**: application/json 934 - **Accept**: application/json 935 936 937 ### HTTP response details 938 939 | Status code | Description | Response headers | 940 |-------------|-------------|------------------| 941 **201** | external principal attached successfully | - | 942 **401** | Unauthorized | - | 943 **404** | Resource Not Found | - | 944 **409** | Resource Conflicts With Target | - | 945 **420** | too many requests | - | 946 **0** | Internal Server Error | - | 947 948 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 949 950 # **delete_credentials** 951 > delete_credentials(user_id, access_key_id) 952 953 delete credentials 954 955 ### Example 956 957 * Basic Authentication (basic_auth): 958 * Api Key Authentication (cookie_auth): 959 * Bearer (JWT) Authentication (jwt_token): 960 * Api Key Authentication (oidc_auth): 961 * Api Key Authentication (saml_auth): 962 963 ```python 964 import time 965 import lakefs_client 966 from lakefs_client.api import auth_api 967 from lakefs_client.model.error import Error 968 from pprint import pprint 969 # Defining the host is optional and defaults to http://localhost/api/v1 970 # See configuration.py for a list of all supported configuration parameters. 971 configuration = lakefs_client.Configuration( 972 host = "http://localhost/api/v1" 973 ) 974 975 # The client must configure the authentication and authorization parameters 976 # in accordance with the API server security policy. 977 # Examples for each auth method are provided below, use the example that 978 # satisfies your auth use case. 979 980 # Configure HTTP basic authorization: basic_auth 981 configuration = lakefs_client.Configuration( 982 username = 'YOUR_USERNAME', 983 password = 'YOUR_PASSWORD' 984 ) 985 986 # Configure API key authorization: cookie_auth 987 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 988 989 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 990 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 991 992 # Configure Bearer authorization (JWT): jwt_token 993 configuration = lakefs_client.Configuration( 994 access_token = 'YOUR_BEARER_TOKEN' 995 ) 996 997 # Configure API key authorization: oidc_auth 998 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 999 1000 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 1001 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 1002 1003 # Configure API key authorization: saml_auth 1004 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 1005 1006 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 1007 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 1008 1009 # Enter a context with an instance of the API client 1010 with lakefs_client.ApiClient(configuration) as api_client: 1011 # Create an instance of the API class 1012 api_instance = auth_api.AuthApi(api_client) 1013 user_id = "userId_example" # str | 1014 access_key_id = "accessKeyId_example" # str | 1015 1016 # example passing only required values which don't have defaults set 1017 try: 1018 # delete credentials 1019 api_instance.delete_credentials(user_id, access_key_id) 1020 except lakefs_client.ApiException as e: 1021 print("Exception when calling AuthApi->delete_credentials: %s\n" % e) 1022 ``` 1023 1024 1025 ### Parameters 1026 1027 Name | Type | Description | Notes 1028 ------------- | ------------- | ------------- | ------------- 1029 **user_id** | **str**| | 1030 **access_key_id** | **str**| | 1031 1032 ### Return type 1033 1034 void (empty response body) 1035 1036 ### Authorization 1037 1038 [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) 1039 1040 ### HTTP request headers 1041 1042 - **Content-Type**: Not defined 1043 - **Accept**: application/json 1044 1045 1046 ### HTTP response details 1047 1048 | Status code | Description | Response headers | 1049 |-------------|-------------|------------------| 1050 **204** | credentials deleted successfully | - | 1051 **401** | Unauthorized | - | 1052 **404** | Resource Not Found | - | 1053 **420** | too many requests | - | 1054 **0** | Internal Server Error | - | 1055 1056 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 1057 1058 # **delete_group** 1059 > delete_group(group_id) 1060 1061 delete group 1062 1063 ### Example 1064 1065 * Basic Authentication (basic_auth): 1066 * Api Key Authentication (cookie_auth): 1067 * Bearer (JWT) Authentication (jwt_token): 1068 * Api Key Authentication (oidc_auth): 1069 * Api Key Authentication (saml_auth): 1070 1071 ```python 1072 import time 1073 import lakefs_client 1074 from lakefs_client.api import auth_api 1075 from lakefs_client.model.error import Error 1076 from pprint import pprint 1077 # Defining the host is optional and defaults to http://localhost/api/v1 1078 # See configuration.py for a list of all supported configuration parameters. 1079 configuration = lakefs_client.Configuration( 1080 host = "http://localhost/api/v1" 1081 ) 1082 1083 # The client must configure the authentication and authorization parameters 1084 # in accordance with the API server security policy. 1085 # Examples for each auth method are provided below, use the example that 1086 # satisfies your auth use case. 1087 1088 # Configure HTTP basic authorization: basic_auth 1089 configuration = lakefs_client.Configuration( 1090 username = 'YOUR_USERNAME', 1091 password = 'YOUR_PASSWORD' 1092 ) 1093 1094 # Configure API key authorization: cookie_auth 1095 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 1096 1097 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 1098 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 1099 1100 # Configure Bearer authorization (JWT): jwt_token 1101 configuration = lakefs_client.Configuration( 1102 access_token = 'YOUR_BEARER_TOKEN' 1103 ) 1104 1105 # Configure API key authorization: oidc_auth 1106 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 1107 1108 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 1109 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 1110 1111 # Configure API key authorization: saml_auth 1112 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 1113 1114 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 1115 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 1116 1117 # Enter a context with an instance of the API client 1118 with lakefs_client.ApiClient(configuration) as api_client: 1119 # Create an instance of the API class 1120 api_instance = auth_api.AuthApi(api_client) 1121 group_id = "groupId_example" # str | 1122 1123 # example passing only required values which don't have defaults set 1124 try: 1125 # delete group 1126 api_instance.delete_group(group_id) 1127 except lakefs_client.ApiException as e: 1128 print("Exception when calling AuthApi->delete_group: %s\n" % e) 1129 ``` 1130 1131 1132 ### Parameters 1133 1134 Name | Type | Description | Notes 1135 ------------- | ------------- | ------------- | ------------- 1136 **group_id** | **str**| | 1137 1138 ### Return type 1139 1140 void (empty response body) 1141 1142 ### Authorization 1143 1144 [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) 1145 1146 ### HTTP request headers 1147 1148 - **Content-Type**: Not defined 1149 - **Accept**: application/json 1150 1151 1152 ### HTTP response details 1153 1154 | Status code | Description | Response headers | 1155 |-------------|-------------|------------------| 1156 **204** | group deleted successfully | - | 1157 **401** | Unauthorized | - | 1158 **404** | Resource Not Found | - | 1159 **420** | too many requests | - | 1160 **0** | Internal Server Error | - | 1161 1162 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 1163 1164 # **delete_group_membership** 1165 > delete_group_membership(group_id, user_id) 1166 1167 delete group membership 1168 1169 ### Example 1170 1171 * Basic Authentication (basic_auth): 1172 * Api Key Authentication (cookie_auth): 1173 * Bearer (JWT) Authentication (jwt_token): 1174 * Api Key Authentication (oidc_auth): 1175 * Api Key Authentication (saml_auth): 1176 1177 ```python 1178 import time 1179 import lakefs_client 1180 from lakefs_client.api import auth_api 1181 from lakefs_client.model.error import Error 1182 from pprint import pprint 1183 # Defining the host is optional and defaults to http://localhost/api/v1 1184 # See configuration.py for a list of all supported configuration parameters. 1185 configuration = lakefs_client.Configuration( 1186 host = "http://localhost/api/v1" 1187 ) 1188 1189 # The client must configure the authentication and authorization parameters 1190 # in accordance with the API server security policy. 1191 # Examples for each auth method are provided below, use the example that 1192 # satisfies your auth use case. 1193 1194 # Configure HTTP basic authorization: basic_auth 1195 configuration = lakefs_client.Configuration( 1196 username = 'YOUR_USERNAME', 1197 password = 'YOUR_PASSWORD' 1198 ) 1199 1200 # Configure API key authorization: cookie_auth 1201 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 1202 1203 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 1204 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 1205 1206 # Configure Bearer authorization (JWT): jwt_token 1207 configuration = lakefs_client.Configuration( 1208 access_token = 'YOUR_BEARER_TOKEN' 1209 ) 1210 1211 # Configure API key authorization: oidc_auth 1212 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 1213 1214 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 1215 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 1216 1217 # Configure API key authorization: saml_auth 1218 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 1219 1220 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 1221 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 1222 1223 # Enter a context with an instance of the API client 1224 with lakefs_client.ApiClient(configuration) as api_client: 1225 # Create an instance of the API class 1226 api_instance = auth_api.AuthApi(api_client) 1227 group_id = "groupId_example" # str | 1228 user_id = "userId_example" # str | 1229 1230 # example passing only required values which don't have defaults set 1231 try: 1232 # delete group membership 1233 api_instance.delete_group_membership(group_id, user_id) 1234 except lakefs_client.ApiException as e: 1235 print("Exception when calling AuthApi->delete_group_membership: %s\n" % e) 1236 ``` 1237 1238 1239 ### Parameters 1240 1241 Name | Type | Description | Notes 1242 ------------- | ------------- | ------------- | ------------- 1243 **group_id** | **str**| | 1244 **user_id** | **str**| | 1245 1246 ### Return type 1247 1248 void (empty response body) 1249 1250 ### Authorization 1251 1252 [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) 1253 1254 ### HTTP request headers 1255 1256 - **Content-Type**: Not defined 1257 - **Accept**: application/json 1258 1259 1260 ### HTTP response details 1261 1262 | Status code | Description | Response headers | 1263 |-------------|-------------|------------------| 1264 **204** | membership deleted successfully | - | 1265 **401** | Unauthorized | - | 1266 **404** | Resource Not Found | - | 1267 **420** | too many requests | - | 1268 **0** | Internal Server Error | - | 1269 1270 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 1271 1272 # **delete_policy** 1273 > delete_policy(policy_id) 1274 1275 delete policy 1276 1277 ### Example 1278 1279 * Basic Authentication (basic_auth): 1280 * Api Key Authentication (cookie_auth): 1281 * Bearer (JWT) Authentication (jwt_token): 1282 * Api Key Authentication (oidc_auth): 1283 * Api Key Authentication (saml_auth): 1284 1285 ```python 1286 import time 1287 import lakefs_client 1288 from lakefs_client.api import auth_api 1289 from lakefs_client.model.error import Error 1290 from pprint import pprint 1291 # Defining the host is optional and defaults to http://localhost/api/v1 1292 # See configuration.py for a list of all supported configuration parameters. 1293 configuration = lakefs_client.Configuration( 1294 host = "http://localhost/api/v1" 1295 ) 1296 1297 # The client must configure the authentication and authorization parameters 1298 # in accordance with the API server security policy. 1299 # Examples for each auth method are provided below, use the example that 1300 # satisfies your auth use case. 1301 1302 # Configure HTTP basic authorization: basic_auth 1303 configuration = lakefs_client.Configuration( 1304 username = 'YOUR_USERNAME', 1305 password = 'YOUR_PASSWORD' 1306 ) 1307 1308 # Configure API key authorization: cookie_auth 1309 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 1310 1311 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 1312 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 1313 1314 # Configure Bearer authorization (JWT): jwt_token 1315 configuration = lakefs_client.Configuration( 1316 access_token = 'YOUR_BEARER_TOKEN' 1317 ) 1318 1319 # Configure API key authorization: oidc_auth 1320 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 1321 1322 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 1323 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 1324 1325 # Configure API key authorization: saml_auth 1326 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 1327 1328 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 1329 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 1330 1331 # Enter a context with an instance of the API client 1332 with lakefs_client.ApiClient(configuration) as api_client: 1333 # Create an instance of the API class 1334 api_instance = auth_api.AuthApi(api_client) 1335 policy_id = "policyId_example" # str | 1336 1337 # example passing only required values which don't have defaults set 1338 try: 1339 # delete policy 1340 api_instance.delete_policy(policy_id) 1341 except lakefs_client.ApiException as e: 1342 print("Exception when calling AuthApi->delete_policy: %s\n" % e) 1343 ``` 1344 1345 1346 ### Parameters 1347 1348 Name | Type | Description | Notes 1349 ------------- | ------------- | ------------- | ------------- 1350 **policy_id** | **str**| | 1351 1352 ### Return type 1353 1354 void (empty response body) 1355 1356 ### Authorization 1357 1358 [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) 1359 1360 ### HTTP request headers 1361 1362 - **Content-Type**: Not defined 1363 - **Accept**: application/json 1364 1365 1366 ### HTTP response details 1367 1368 | Status code | Description | Response headers | 1369 |-------------|-------------|------------------| 1370 **204** | policy deleted successfully | - | 1371 **401** | Unauthorized | - | 1372 **404** | Resource Not Found | - | 1373 **420** | too many requests | - | 1374 **0** | Internal Server Error | - | 1375 1376 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 1377 1378 # **delete_user** 1379 > delete_user(user_id) 1380 1381 delete user 1382 1383 ### Example 1384 1385 * Basic Authentication (basic_auth): 1386 * Api Key Authentication (cookie_auth): 1387 * Bearer (JWT) Authentication (jwt_token): 1388 * Api Key Authentication (oidc_auth): 1389 * Api Key Authentication (saml_auth): 1390 1391 ```python 1392 import time 1393 import lakefs_client 1394 from lakefs_client.api import auth_api 1395 from lakefs_client.model.error import Error 1396 from pprint import pprint 1397 # Defining the host is optional and defaults to http://localhost/api/v1 1398 # See configuration.py for a list of all supported configuration parameters. 1399 configuration = lakefs_client.Configuration( 1400 host = "http://localhost/api/v1" 1401 ) 1402 1403 # The client must configure the authentication and authorization parameters 1404 # in accordance with the API server security policy. 1405 # Examples for each auth method are provided below, use the example that 1406 # satisfies your auth use case. 1407 1408 # Configure HTTP basic authorization: basic_auth 1409 configuration = lakefs_client.Configuration( 1410 username = 'YOUR_USERNAME', 1411 password = 'YOUR_PASSWORD' 1412 ) 1413 1414 # Configure API key authorization: cookie_auth 1415 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 1416 1417 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 1418 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 1419 1420 # Configure Bearer authorization (JWT): jwt_token 1421 configuration = lakefs_client.Configuration( 1422 access_token = 'YOUR_BEARER_TOKEN' 1423 ) 1424 1425 # Configure API key authorization: oidc_auth 1426 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 1427 1428 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 1429 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 1430 1431 # Configure API key authorization: saml_auth 1432 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 1433 1434 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 1435 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 1436 1437 # Enter a context with an instance of the API client 1438 with lakefs_client.ApiClient(configuration) as api_client: 1439 # Create an instance of the API class 1440 api_instance = auth_api.AuthApi(api_client) 1441 user_id = "userId_example" # str | 1442 1443 # example passing only required values which don't have defaults set 1444 try: 1445 # delete user 1446 api_instance.delete_user(user_id) 1447 except lakefs_client.ApiException as e: 1448 print("Exception when calling AuthApi->delete_user: %s\n" % e) 1449 ``` 1450 1451 1452 ### Parameters 1453 1454 Name | Type | Description | Notes 1455 ------------- | ------------- | ------------- | ------------- 1456 **user_id** | **str**| | 1457 1458 ### Return type 1459 1460 void (empty response body) 1461 1462 ### Authorization 1463 1464 [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) 1465 1466 ### HTTP request headers 1467 1468 - **Content-Type**: Not defined 1469 - **Accept**: application/json 1470 1471 1472 ### HTTP response details 1473 1474 | Status code | Description | Response headers | 1475 |-------------|-------------|------------------| 1476 **204** | user deleted successfully | - | 1477 **401** | Unauthorized | - | 1478 **404** | Resource Not Found | - | 1479 **420** | too many requests | - | 1480 **0** | Internal Server Error | - | 1481 1482 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 1483 1484 # **delete_user_external_principal** 1485 > delete_user_external_principal(user_id, principal_id) 1486 1487 delete external principal from user 1488 1489 ### Example 1490 1491 * Basic Authentication (basic_auth): 1492 * Api Key Authentication (cookie_auth): 1493 * Bearer (JWT) Authentication (jwt_token): 1494 * Api Key Authentication (oidc_auth): 1495 * Api Key Authentication (saml_auth): 1496 1497 ```python 1498 import time 1499 import lakefs_client 1500 from lakefs_client.api import auth_api 1501 from lakefs_client.model.error import Error 1502 from pprint import pprint 1503 # Defining the host is optional and defaults to http://localhost/api/v1 1504 # See configuration.py for a list of all supported configuration parameters. 1505 configuration = lakefs_client.Configuration( 1506 host = "http://localhost/api/v1" 1507 ) 1508 1509 # The client must configure the authentication and authorization parameters 1510 # in accordance with the API server security policy. 1511 # Examples for each auth method are provided below, use the example that 1512 # satisfies your auth use case. 1513 1514 # Configure HTTP basic authorization: basic_auth 1515 configuration = lakefs_client.Configuration( 1516 username = 'YOUR_USERNAME', 1517 password = 'YOUR_PASSWORD' 1518 ) 1519 1520 # Configure API key authorization: cookie_auth 1521 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 1522 1523 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 1524 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 1525 1526 # Configure Bearer authorization (JWT): jwt_token 1527 configuration = lakefs_client.Configuration( 1528 access_token = 'YOUR_BEARER_TOKEN' 1529 ) 1530 1531 # Configure API key authorization: oidc_auth 1532 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 1533 1534 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 1535 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 1536 1537 # Configure API key authorization: saml_auth 1538 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 1539 1540 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 1541 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 1542 1543 # Enter a context with an instance of the API client 1544 with lakefs_client.ApiClient(configuration) as api_client: 1545 # Create an instance of the API class 1546 api_instance = auth_api.AuthApi(api_client) 1547 user_id = "userId_example" # str | 1548 principal_id = "principalId_example" # str | 1549 1550 # example passing only required values which don't have defaults set 1551 try: 1552 # delete external principal from user 1553 api_instance.delete_user_external_principal(user_id, principal_id) 1554 except lakefs_client.ApiException as e: 1555 print("Exception when calling AuthApi->delete_user_external_principal: %s\n" % e) 1556 ``` 1557 1558 1559 ### Parameters 1560 1561 Name | Type | Description | Notes 1562 ------------- | ------------- | ------------- | ------------- 1563 **user_id** | **str**| | 1564 **principal_id** | **str**| | 1565 1566 ### Return type 1567 1568 void (empty response body) 1569 1570 ### Authorization 1571 1572 [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) 1573 1574 ### HTTP request headers 1575 1576 - **Content-Type**: Not defined 1577 - **Accept**: application/json 1578 1579 1580 ### HTTP response details 1581 1582 | Status code | Description | Response headers | 1583 |-------------|-------------|------------------| 1584 **204** | external principal detached successfully | - | 1585 **401** | Unauthorized | - | 1586 **404** | Resource Not Found | - | 1587 **420** | too many requests | - | 1588 **0** | Internal Server Error | - | 1589 1590 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 1591 1592 # **detach_policy_from_group** 1593 > detach_policy_from_group(group_id, policy_id) 1594 1595 detach policy from group 1596 1597 ### Example 1598 1599 * Basic Authentication (basic_auth): 1600 * Api Key Authentication (cookie_auth): 1601 * Bearer (JWT) Authentication (jwt_token): 1602 * Api Key Authentication (oidc_auth): 1603 * Api Key Authentication (saml_auth): 1604 1605 ```python 1606 import time 1607 import lakefs_client 1608 from lakefs_client.api import auth_api 1609 from lakefs_client.model.error import Error 1610 from pprint import pprint 1611 # Defining the host is optional and defaults to http://localhost/api/v1 1612 # See configuration.py for a list of all supported configuration parameters. 1613 configuration = lakefs_client.Configuration( 1614 host = "http://localhost/api/v1" 1615 ) 1616 1617 # The client must configure the authentication and authorization parameters 1618 # in accordance with the API server security policy. 1619 # Examples for each auth method are provided below, use the example that 1620 # satisfies your auth use case. 1621 1622 # Configure HTTP basic authorization: basic_auth 1623 configuration = lakefs_client.Configuration( 1624 username = 'YOUR_USERNAME', 1625 password = 'YOUR_PASSWORD' 1626 ) 1627 1628 # Configure API key authorization: cookie_auth 1629 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 1630 1631 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 1632 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 1633 1634 # Configure Bearer authorization (JWT): jwt_token 1635 configuration = lakefs_client.Configuration( 1636 access_token = 'YOUR_BEARER_TOKEN' 1637 ) 1638 1639 # Configure API key authorization: oidc_auth 1640 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 1641 1642 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 1643 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 1644 1645 # Configure API key authorization: saml_auth 1646 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 1647 1648 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 1649 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 1650 1651 # Enter a context with an instance of the API client 1652 with lakefs_client.ApiClient(configuration) as api_client: 1653 # Create an instance of the API class 1654 api_instance = auth_api.AuthApi(api_client) 1655 group_id = "groupId_example" # str | 1656 policy_id = "policyId_example" # str | 1657 1658 # example passing only required values which don't have defaults set 1659 try: 1660 # detach policy from group 1661 api_instance.detach_policy_from_group(group_id, policy_id) 1662 except lakefs_client.ApiException as e: 1663 print("Exception when calling AuthApi->detach_policy_from_group: %s\n" % e) 1664 ``` 1665 1666 1667 ### Parameters 1668 1669 Name | Type | Description | Notes 1670 ------------- | ------------- | ------------- | ------------- 1671 **group_id** | **str**| | 1672 **policy_id** | **str**| | 1673 1674 ### Return type 1675 1676 void (empty response body) 1677 1678 ### Authorization 1679 1680 [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) 1681 1682 ### HTTP request headers 1683 1684 - **Content-Type**: Not defined 1685 - **Accept**: application/json 1686 1687 1688 ### HTTP response details 1689 1690 | Status code | Description | Response headers | 1691 |-------------|-------------|------------------| 1692 **204** | policy detached successfully | - | 1693 **401** | Unauthorized | - | 1694 **404** | Resource Not Found | - | 1695 **420** | too many requests | - | 1696 **0** | Internal Server Error | - | 1697 1698 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 1699 1700 # **detach_policy_from_user** 1701 > detach_policy_from_user(user_id, policy_id) 1702 1703 detach policy from user 1704 1705 ### Example 1706 1707 * Basic Authentication (basic_auth): 1708 * Api Key Authentication (cookie_auth): 1709 * Bearer (JWT) Authentication (jwt_token): 1710 * Api Key Authentication (oidc_auth): 1711 * Api Key Authentication (saml_auth): 1712 1713 ```python 1714 import time 1715 import lakefs_client 1716 from lakefs_client.api import auth_api 1717 from lakefs_client.model.error import Error 1718 from pprint import pprint 1719 # Defining the host is optional and defaults to http://localhost/api/v1 1720 # See configuration.py for a list of all supported configuration parameters. 1721 configuration = lakefs_client.Configuration( 1722 host = "http://localhost/api/v1" 1723 ) 1724 1725 # The client must configure the authentication and authorization parameters 1726 # in accordance with the API server security policy. 1727 # Examples for each auth method are provided below, use the example that 1728 # satisfies your auth use case. 1729 1730 # Configure HTTP basic authorization: basic_auth 1731 configuration = lakefs_client.Configuration( 1732 username = 'YOUR_USERNAME', 1733 password = 'YOUR_PASSWORD' 1734 ) 1735 1736 # Configure API key authorization: cookie_auth 1737 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 1738 1739 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 1740 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 1741 1742 # Configure Bearer authorization (JWT): jwt_token 1743 configuration = lakefs_client.Configuration( 1744 access_token = 'YOUR_BEARER_TOKEN' 1745 ) 1746 1747 # Configure API key authorization: oidc_auth 1748 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 1749 1750 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 1751 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 1752 1753 # Configure API key authorization: saml_auth 1754 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 1755 1756 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 1757 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 1758 1759 # Enter a context with an instance of the API client 1760 with lakefs_client.ApiClient(configuration) as api_client: 1761 # Create an instance of the API class 1762 api_instance = auth_api.AuthApi(api_client) 1763 user_id = "userId_example" # str | 1764 policy_id = "policyId_example" # str | 1765 1766 # example passing only required values which don't have defaults set 1767 try: 1768 # detach policy from user 1769 api_instance.detach_policy_from_user(user_id, policy_id) 1770 except lakefs_client.ApiException as e: 1771 print("Exception when calling AuthApi->detach_policy_from_user: %s\n" % e) 1772 ``` 1773 1774 1775 ### Parameters 1776 1777 Name | Type | Description | Notes 1778 ------------- | ------------- | ------------- | ------------- 1779 **user_id** | **str**| | 1780 **policy_id** | **str**| | 1781 1782 ### Return type 1783 1784 void (empty response body) 1785 1786 ### Authorization 1787 1788 [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) 1789 1790 ### HTTP request headers 1791 1792 - **Content-Type**: Not defined 1793 - **Accept**: application/json 1794 1795 1796 ### HTTP response details 1797 1798 | Status code | Description | Response headers | 1799 |-------------|-------------|------------------| 1800 **204** | policy detached successfully | - | 1801 **401** | Unauthorized | - | 1802 **404** | Resource Not Found | - | 1803 **420** | too many requests | - | 1804 **0** | Internal Server Error | - | 1805 1806 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 1807 1808 # **external_principal_login** 1809 > AuthenticationToken external_principal_login() 1810 1811 perform a login using an external authenticator 1812 1813 ### Example 1814 1815 1816 ```python 1817 import time 1818 import lakefs_client 1819 from lakefs_client.api import auth_api 1820 from lakefs_client.model.authentication_token import AuthenticationToken 1821 from lakefs_client.model.external_login_information import ExternalLoginInformation 1822 from lakefs_client.model.error import Error 1823 from pprint import pprint 1824 # Defining the host is optional and defaults to http://localhost/api/v1 1825 # See configuration.py for a list of all supported configuration parameters. 1826 configuration = lakefs_client.Configuration( 1827 host = "http://localhost/api/v1" 1828 ) 1829 1830 1831 # Enter a context with an instance of the API client 1832 with lakefs_client.ApiClient() as api_client: 1833 # Create an instance of the API class 1834 api_instance = auth_api.AuthApi(api_client) 1835 external_login_information = ExternalLoginInformation( 1836 token_expiration_duration=1, 1837 identity_request={}, 1838 ) # ExternalLoginInformation | (optional) 1839 1840 # example passing only required values which don't have defaults set 1841 # and optional values 1842 try: 1843 # perform a login using an external authenticator 1844 api_response = api_instance.external_principal_login(external_login_information=external_login_information) 1845 pprint(api_response) 1846 except lakefs_client.ApiException as e: 1847 print("Exception when calling AuthApi->external_principal_login: %s\n" % e) 1848 ``` 1849 1850 1851 ### Parameters 1852 1853 Name | Type | Description | Notes 1854 ------------- | ------------- | ------------- | ------------- 1855 **external_login_information** | [**ExternalLoginInformation**](ExternalLoginInformation.md)| | [optional] 1856 1857 ### Return type 1858 1859 [**AuthenticationToken**](AuthenticationToken.md) 1860 1861 ### Authorization 1862 1863 No authorization required 1864 1865 ### HTTP request headers 1866 1867 - **Content-Type**: application/json 1868 - **Accept**: application/json 1869 1870 1871 ### HTTP response details 1872 1873 | Status code | Description | Response headers | 1874 |-------------|-------------|------------------| 1875 **200** | successful external login | - | 1876 **400** | Bad Request | - | 1877 **401** | Unauthorized | - | 1878 **403** | Forbidden | - | 1879 **404** | Resource Not Found | - | 1880 **420** | too many requests | - | 1881 **0** | Internal Server Error | - | 1882 1883 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 1884 1885 # **get_credentials** 1886 > Credentials get_credentials(user_id, access_key_id) 1887 1888 get credentials 1889 1890 ### Example 1891 1892 * Basic Authentication (basic_auth): 1893 * Api Key Authentication (cookie_auth): 1894 * Bearer (JWT) Authentication (jwt_token): 1895 * Api Key Authentication (oidc_auth): 1896 * Api Key Authentication (saml_auth): 1897 1898 ```python 1899 import time 1900 import lakefs_client 1901 from lakefs_client.api import auth_api 1902 from lakefs_client.model.credentials import Credentials 1903 from lakefs_client.model.error import Error 1904 from pprint import pprint 1905 # Defining the host is optional and defaults to http://localhost/api/v1 1906 # See configuration.py for a list of all supported configuration parameters. 1907 configuration = lakefs_client.Configuration( 1908 host = "http://localhost/api/v1" 1909 ) 1910 1911 # The client must configure the authentication and authorization parameters 1912 # in accordance with the API server security policy. 1913 # Examples for each auth method are provided below, use the example that 1914 # satisfies your auth use case. 1915 1916 # Configure HTTP basic authorization: basic_auth 1917 configuration = lakefs_client.Configuration( 1918 username = 'YOUR_USERNAME', 1919 password = 'YOUR_PASSWORD' 1920 ) 1921 1922 # Configure API key authorization: cookie_auth 1923 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 1924 1925 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 1926 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 1927 1928 # Configure Bearer authorization (JWT): jwt_token 1929 configuration = lakefs_client.Configuration( 1930 access_token = 'YOUR_BEARER_TOKEN' 1931 ) 1932 1933 # Configure API key authorization: oidc_auth 1934 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 1935 1936 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 1937 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 1938 1939 # Configure API key authorization: saml_auth 1940 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 1941 1942 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 1943 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 1944 1945 # Enter a context with an instance of the API client 1946 with lakefs_client.ApiClient(configuration) as api_client: 1947 # Create an instance of the API class 1948 api_instance = auth_api.AuthApi(api_client) 1949 user_id = "userId_example" # str | 1950 access_key_id = "accessKeyId_example" # str | 1951 1952 # example passing only required values which don't have defaults set 1953 try: 1954 # get credentials 1955 api_response = api_instance.get_credentials(user_id, access_key_id) 1956 pprint(api_response) 1957 except lakefs_client.ApiException as e: 1958 print("Exception when calling AuthApi->get_credentials: %s\n" % e) 1959 ``` 1960 1961 1962 ### Parameters 1963 1964 Name | Type | Description | Notes 1965 ------------- | ------------- | ------------- | ------------- 1966 **user_id** | **str**| | 1967 **access_key_id** | **str**| | 1968 1969 ### Return type 1970 1971 [**Credentials**](Credentials.md) 1972 1973 ### Authorization 1974 1975 [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) 1976 1977 ### HTTP request headers 1978 1979 - **Content-Type**: Not defined 1980 - **Accept**: application/json 1981 1982 1983 ### HTTP response details 1984 1985 | Status code | Description | Response headers | 1986 |-------------|-------------|------------------| 1987 **200** | credentials | - | 1988 **401** | Unauthorized | - | 1989 **404** | Resource Not Found | - | 1990 **420** | too many requests | - | 1991 **0** | Internal Server Error | - | 1992 1993 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 1994 1995 # **get_current_user** 1996 > CurrentUser get_current_user() 1997 1998 get current user 1999 2000 ### Example 2001 2002 * Basic Authentication (basic_auth): 2003 * Api Key Authentication (cookie_auth): 2004 * Bearer (JWT) Authentication (jwt_token): 2005 * Api Key Authentication (oidc_auth): 2006 * Api Key Authentication (saml_auth): 2007 2008 ```python 2009 import time 2010 import lakefs_client 2011 from lakefs_client.api import auth_api 2012 from lakefs_client.model.current_user import CurrentUser 2013 from pprint import pprint 2014 # Defining the host is optional and defaults to http://localhost/api/v1 2015 # See configuration.py for a list of all supported configuration parameters. 2016 configuration = lakefs_client.Configuration( 2017 host = "http://localhost/api/v1" 2018 ) 2019 2020 # The client must configure the authentication and authorization parameters 2021 # in accordance with the API server security policy. 2022 # Examples for each auth method are provided below, use the example that 2023 # satisfies your auth use case. 2024 2025 # Configure HTTP basic authorization: basic_auth 2026 configuration = lakefs_client.Configuration( 2027 username = 'YOUR_USERNAME', 2028 password = 'YOUR_PASSWORD' 2029 ) 2030 2031 # Configure API key authorization: cookie_auth 2032 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 2033 2034 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 2035 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 2036 2037 # Configure Bearer authorization (JWT): jwt_token 2038 configuration = lakefs_client.Configuration( 2039 access_token = 'YOUR_BEARER_TOKEN' 2040 ) 2041 2042 # Configure API key authorization: oidc_auth 2043 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 2044 2045 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 2046 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 2047 2048 # Configure API key authorization: saml_auth 2049 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 2050 2051 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 2052 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 2053 2054 # Enter a context with an instance of the API client 2055 with lakefs_client.ApiClient(configuration) as api_client: 2056 # Create an instance of the API class 2057 api_instance = auth_api.AuthApi(api_client) 2058 2059 # example, this endpoint has no required or optional parameters 2060 try: 2061 # get current user 2062 api_response = api_instance.get_current_user() 2063 pprint(api_response) 2064 except lakefs_client.ApiException as e: 2065 print("Exception when calling AuthApi->get_current_user: %s\n" % e) 2066 ``` 2067 2068 2069 ### Parameters 2070 This endpoint does not need any parameter. 2071 2072 ### Return type 2073 2074 [**CurrentUser**](CurrentUser.md) 2075 2076 ### Authorization 2077 2078 [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) 2079 2080 ### HTTP request headers 2081 2082 - **Content-Type**: Not defined 2083 - **Accept**: application/json 2084 2085 2086 ### HTTP response details 2087 2088 | Status code | Description | Response headers | 2089 |-------------|-------------|------------------| 2090 **200** | user | - | 2091 2092 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 2093 2094 # **get_external_principal** 2095 > ExternalPrincipal get_external_principal(principal_id) 2096 2097 describe external principal by id 2098 2099 ### Example 2100 2101 * Basic Authentication (basic_auth): 2102 * Api Key Authentication (cookie_auth): 2103 * Bearer (JWT) Authentication (jwt_token): 2104 * Api Key Authentication (oidc_auth): 2105 * Api Key Authentication (saml_auth): 2106 2107 ```python 2108 import time 2109 import lakefs_client 2110 from lakefs_client.api import auth_api 2111 from lakefs_client.model.external_principal import ExternalPrincipal 2112 from lakefs_client.model.error import Error 2113 from pprint import pprint 2114 # Defining the host is optional and defaults to http://localhost/api/v1 2115 # See configuration.py for a list of all supported configuration parameters. 2116 configuration = lakefs_client.Configuration( 2117 host = "http://localhost/api/v1" 2118 ) 2119 2120 # The client must configure the authentication and authorization parameters 2121 # in accordance with the API server security policy. 2122 # Examples for each auth method are provided below, use the example that 2123 # satisfies your auth use case. 2124 2125 # Configure HTTP basic authorization: basic_auth 2126 configuration = lakefs_client.Configuration( 2127 username = 'YOUR_USERNAME', 2128 password = 'YOUR_PASSWORD' 2129 ) 2130 2131 # Configure API key authorization: cookie_auth 2132 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 2133 2134 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 2135 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 2136 2137 # Configure Bearer authorization (JWT): jwt_token 2138 configuration = lakefs_client.Configuration( 2139 access_token = 'YOUR_BEARER_TOKEN' 2140 ) 2141 2142 # Configure API key authorization: oidc_auth 2143 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 2144 2145 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 2146 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 2147 2148 # Configure API key authorization: saml_auth 2149 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 2150 2151 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 2152 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 2153 2154 # Enter a context with an instance of the API client 2155 with lakefs_client.ApiClient(configuration) as api_client: 2156 # Create an instance of the API class 2157 api_instance = auth_api.AuthApi(api_client) 2158 principal_id = "principalId_example" # str | 2159 2160 # example passing only required values which don't have defaults set 2161 try: 2162 # describe external principal by id 2163 api_response = api_instance.get_external_principal(principal_id) 2164 pprint(api_response) 2165 except lakefs_client.ApiException as e: 2166 print("Exception when calling AuthApi->get_external_principal: %s\n" % e) 2167 ``` 2168 2169 2170 ### Parameters 2171 2172 Name | Type | Description | Notes 2173 ------------- | ------------- | ------------- | ------------- 2174 **principal_id** | **str**| | 2175 2176 ### Return type 2177 2178 [**ExternalPrincipal**](ExternalPrincipal.md) 2179 2180 ### Authorization 2181 2182 [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) 2183 2184 ### HTTP request headers 2185 2186 - **Content-Type**: Not defined 2187 - **Accept**: application/json 2188 2189 2190 ### HTTP response details 2191 2192 | Status code | Description | Response headers | 2193 |-------------|-------------|------------------| 2194 **200** | external principal | - | 2195 **401** | Unauthorized | - | 2196 **404** | Resource Not Found | - | 2197 **420** | too many requests | - | 2198 **0** | Internal Server Error | - | 2199 2200 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 2201 2202 # **get_group** 2203 > Group get_group(group_id) 2204 2205 get group 2206 2207 ### Example 2208 2209 * Basic Authentication (basic_auth): 2210 * Api Key Authentication (cookie_auth): 2211 * Bearer (JWT) Authentication (jwt_token): 2212 * Api Key Authentication (oidc_auth): 2213 * Api Key Authentication (saml_auth): 2214 2215 ```python 2216 import time 2217 import lakefs_client 2218 from lakefs_client.api import auth_api 2219 from lakefs_client.model.error import Error 2220 from lakefs_client.model.group import Group 2221 from pprint import pprint 2222 # Defining the host is optional and defaults to http://localhost/api/v1 2223 # See configuration.py for a list of all supported configuration parameters. 2224 configuration = lakefs_client.Configuration( 2225 host = "http://localhost/api/v1" 2226 ) 2227 2228 # The client must configure the authentication and authorization parameters 2229 # in accordance with the API server security policy. 2230 # Examples for each auth method are provided below, use the example that 2231 # satisfies your auth use case. 2232 2233 # Configure HTTP basic authorization: basic_auth 2234 configuration = lakefs_client.Configuration( 2235 username = 'YOUR_USERNAME', 2236 password = 'YOUR_PASSWORD' 2237 ) 2238 2239 # Configure API key authorization: cookie_auth 2240 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 2241 2242 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 2243 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 2244 2245 # Configure Bearer authorization (JWT): jwt_token 2246 configuration = lakefs_client.Configuration( 2247 access_token = 'YOUR_BEARER_TOKEN' 2248 ) 2249 2250 # Configure API key authorization: oidc_auth 2251 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 2252 2253 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 2254 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 2255 2256 # Configure API key authorization: saml_auth 2257 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 2258 2259 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 2260 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 2261 2262 # Enter a context with an instance of the API client 2263 with lakefs_client.ApiClient(configuration) as api_client: 2264 # Create an instance of the API class 2265 api_instance = auth_api.AuthApi(api_client) 2266 group_id = "groupId_example" # str | 2267 2268 # example passing only required values which don't have defaults set 2269 try: 2270 # get group 2271 api_response = api_instance.get_group(group_id) 2272 pprint(api_response) 2273 except lakefs_client.ApiException as e: 2274 print("Exception when calling AuthApi->get_group: %s\n" % e) 2275 ``` 2276 2277 2278 ### Parameters 2279 2280 Name | Type | Description | Notes 2281 ------------- | ------------- | ------------- | ------------- 2282 **group_id** | **str**| | 2283 2284 ### Return type 2285 2286 [**Group**](Group.md) 2287 2288 ### Authorization 2289 2290 [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) 2291 2292 ### HTTP request headers 2293 2294 - **Content-Type**: Not defined 2295 - **Accept**: application/json 2296 2297 2298 ### HTTP response details 2299 2300 | Status code | Description | Response headers | 2301 |-------------|-------------|------------------| 2302 **200** | group | - | 2303 **401** | Unauthorized | - | 2304 **404** | Resource Not Found | - | 2305 **420** | too many requests | - | 2306 **0** | Internal Server Error | - | 2307 2308 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 2309 2310 # **get_group_acl** 2311 > ACL get_group_acl(group_id) 2312 2313 get ACL of group 2314 2315 ### Example 2316 2317 * Basic Authentication (basic_auth): 2318 * Api Key Authentication (cookie_auth): 2319 * Bearer (JWT) Authentication (jwt_token): 2320 * Api Key Authentication (oidc_auth): 2321 * Api Key Authentication (saml_auth): 2322 2323 ```python 2324 import time 2325 import lakefs_client 2326 from lakefs_client.api import auth_api 2327 from lakefs_client.model.acl import ACL 2328 from lakefs_client.model.error_no_acl import ErrorNoACL 2329 from lakefs_client.model.error import Error 2330 from pprint import pprint 2331 # Defining the host is optional and defaults to http://localhost/api/v1 2332 # See configuration.py for a list of all supported configuration parameters. 2333 configuration = lakefs_client.Configuration( 2334 host = "http://localhost/api/v1" 2335 ) 2336 2337 # The client must configure the authentication and authorization parameters 2338 # in accordance with the API server security policy. 2339 # Examples for each auth method are provided below, use the example that 2340 # satisfies your auth use case. 2341 2342 # Configure HTTP basic authorization: basic_auth 2343 configuration = lakefs_client.Configuration( 2344 username = 'YOUR_USERNAME', 2345 password = 'YOUR_PASSWORD' 2346 ) 2347 2348 # Configure API key authorization: cookie_auth 2349 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 2350 2351 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 2352 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 2353 2354 # Configure Bearer authorization (JWT): jwt_token 2355 configuration = lakefs_client.Configuration( 2356 access_token = 'YOUR_BEARER_TOKEN' 2357 ) 2358 2359 # Configure API key authorization: oidc_auth 2360 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 2361 2362 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 2363 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 2364 2365 # Configure API key authorization: saml_auth 2366 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 2367 2368 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 2369 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 2370 2371 # Enter a context with an instance of the API client 2372 with lakefs_client.ApiClient(configuration) as api_client: 2373 # Create an instance of the API class 2374 api_instance = auth_api.AuthApi(api_client) 2375 group_id = "groupId_example" # str | 2376 2377 # example passing only required values which don't have defaults set 2378 try: 2379 # get ACL of group 2380 api_response = api_instance.get_group_acl(group_id) 2381 pprint(api_response) 2382 except lakefs_client.ApiException as e: 2383 print("Exception when calling AuthApi->get_group_acl: %s\n" % e) 2384 ``` 2385 2386 2387 ### Parameters 2388 2389 Name | Type | Description | Notes 2390 ------------- | ------------- | ------------- | ------------- 2391 **group_id** | **str**| | 2392 2393 ### Return type 2394 2395 [**ACL**](ACL.md) 2396 2397 ### Authorization 2398 2399 [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) 2400 2401 ### HTTP request headers 2402 2403 - **Content-Type**: Not defined 2404 - **Accept**: application/json 2405 2406 2407 ### HTTP response details 2408 2409 | Status code | Description | Response headers | 2410 |-------------|-------------|------------------| 2411 **200** | ACL of group | - | 2412 **401** | Unauthorized | - | 2413 **404** | Group not found, or group found but has no ACL | - | 2414 **420** | too many requests | - | 2415 **0** | Internal Server Error | - | 2416 2417 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 2418 2419 # **get_policy** 2420 > Policy get_policy(policy_id) 2421 2422 get policy 2423 2424 ### Example 2425 2426 * Basic Authentication (basic_auth): 2427 * Api Key Authentication (cookie_auth): 2428 * Bearer (JWT) Authentication (jwt_token): 2429 * Api Key Authentication (oidc_auth): 2430 * Api Key Authentication (saml_auth): 2431 2432 ```python 2433 import time 2434 import lakefs_client 2435 from lakefs_client.api import auth_api 2436 from lakefs_client.model.policy import Policy 2437 from lakefs_client.model.error import Error 2438 from pprint import pprint 2439 # Defining the host is optional and defaults to http://localhost/api/v1 2440 # See configuration.py for a list of all supported configuration parameters. 2441 configuration = lakefs_client.Configuration( 2442 host = "http://localhost/api/v1" 2443 ) 2444 2445 # The client must configure the authentication and authorization parameters 2446 # in accordance with the API server security policy. 2447 # Examples for each auth method are provided below, use the example that 2448 # satisfies your auth use case. 2449 2450 # Configure HTTP basic authorization: basic_auth 2451 configuration = lakefs_client.Configuration( 2452 username = 'YOUR_USERNAME', 2453 password = 'YOUR_PASSWORD' 2454 ) 2455 2456 # Configure API key authorization: cookie_auth 2457 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 2458 2459 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 2460 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 2461 2462 # Configure Bearer authorization (JWT): jwt_token 2463 configuration = lakefs_client.Configuration( 2464 access_token = 'YOUR_BEARER_TOKEN' 2465 ) 2466 2467 # Configure API key authorization: oidc_auth 2468 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 2469 2470 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 2471 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 2472 2473 # Configure API key authorization: saml_auth 2474 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 2475 2476 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 2477 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 2478 2479 # Enter a context with an instance of the API client 2480 with lakefs_client.ApiClient(configuration) as api_client: 2481 # Create an instance of the API class 2482 api_instance = auth_api.AuthApi(api_client) 2483 policy_id = "policyId_example" # str | 2484 2485 # example passing only required values which don't have defaults set 2486 try: 2487 # get policy 2488 api_response = api_instance.get_policy(policy_id) 2489 pprint(api_response) 2490 except lakefs_client.ApiException as e: 2491 print("Exception when calling AuthApi->get_policy: %s\n" % e) 2492 ``` 2493 2494 2495 ### Parameters 2496 2497 Name | Type | Description | Notes 2498 ------------- | ------------- | ------------- | ------------- 2499 **policy_id** | **str**| | 2500 2501 ### Return type 2502 2503 [**Policy**](Policy.md) 2504 2505 ### Authorization 2506 2507 [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) 2508 2509 ### HTTP request headers 2510 2511 - **Content-Type**: Not defined 2512 - **Accept**: application/json 2513 2514 2515 ### HTTP response details 2516 2517 | Status code | Description | Response headers | 2518 |-------------|-------------|------------------| 2519 **200** | policy | - | 2520 **401** | Unauthorized | - | 2521 **404** | Resource Not Found | - | 2522 **420** | too many requests | - | 2523 **0** | Internal Server Error | - | 2524 2525 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 2526 2527 # **get_user** 2528 > User get_user(user_id) 2529 2530 get user 2531 2532 ### Example 2533 2534 * Basic Authentication (basic_auth): 2535 * Api Key Authentication (cookie_auth): 2536 * Bearer (JWT) Authentication (jwt_token): 2537 * Api Key Authentication (oidc_auth): 2538 * Api Key Authentication (saml_auth): 2539 2540 ```python 2541 import time 2542 import lakefs_client 2543 from lakefs_client.api import auth_api 2544 from lakefs_client.model.error import Error 2545 from lakefs_client.model.user import User 2546 from pprint import pprint 2547 # Defining the host is optional and defaults to http://localhost/api/v1 2548 # See configuration.py for a list of all supported configuration parameters. 2549 configuration = lakefs_client.Configuration( 2550 host = "http://localhost/api/v1" 2551 ) 2552 2553 # The client must configure the authentication and authorization parameters 2554 # in accordance with the API server security policy. 2555 # Examples for each auth method are provided below, use the example that 2556 # satisfies your auth use case. 2557 2558 # Configure HTTP basic authorization: basic_auth 2559 configuration = lakefs_client.Configuration( 2560 username = 'YOUR_USERNAME', 2561 password = 'YOUR_PASSWORD' 2562 ) 2563 2564 # Configure API key authorization: cookie_auth 2565 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 2566 2567 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 2568 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 2569 2570 # Configure Bearer authorization (JWT): jwt_token 2571 configuration = lakefs_client.Configuration( 2572 access_token = 'YOUR_BEARER_TOKEN' 2573 ) 2574 2575 # Configure API key authorization: oidc_auth 2576 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 2577 2578 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 2579 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 2580 2581 # Configure API key authorization: saml_auth 2582 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 2583 2584 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 2585 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 2586 2587 # Enter a context with an instance of the API client 2588 with lakefs_client.ApiClient(configuration) as api_client: 2589 # Create an instance of the API class 2590 api_instance = auth_api.AuthApi(api_client) 2591 user_id = "userId_example" # str | 2592 2593 # example passing only required values which don't have defaults set 2594 try: 2595 # get user 2596 api_response = api_instance.get_user(user_id) 2597 pprint(api_response) 2598 except lakefs_client.ApiException as e: 2599 print("Exception when calling AuthApi->get_user: %s\n" % e) 2600 ``` 2601 2602 2603 ### Parameters 2604 2605 Name | Type | Description | Notes 2606 ------------- | ------------- | ------------- | ------------- 2607 **user_id** | **str**| | 2608 2609 ### Return type 2610 2611 [**User**](User.md) 2612 2613 ### Authorization 2614 2615 [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) 2616 2617 ### HTTP request headers 2618 2619 - **Content-Type**: Not defined 2620 - **Accept**: application/json 2621 2622 2623 ### HTTP response details 2624 2625 | Status code | Description | Response headers | 2626 |-------------|-------------|------------------| 2627 **200** | user | - | 2628 **401** | Unauthorized | - | 2629 **404** | Resource Not Found | - | 2630 **420** | too many requests | - | 2631 **0** | Internal Server Error | - | 2632 2633 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 2634 2635 # **list_group_members** 2636 > UserList list_group_members(group_id) 2637 2638 list group members 2639 2640 ### Example 2641 2642 * Basic Authentication (basic_auth): 2643 * Api Key Authentication (cookie_auth): 2644 * Bearer (JWT) Authentication (jwt_token): 2645 * Api Key Authentication (oidc_auth): 2646 * Api Key Authentication (saml_auth): 2647 2648 ```python 2649 import time 2650 import lakefs_client 2651 from lakefs_client.api import auth_api 2652 from lakefs_client.model.user_list import UserList 2653 from lakefs_client.model.error import Error 2654 from pprint import pprint 2655 # Defining the host is optional and defaults to http://localhost/api/v1 2656 # See configuration.py for a list of all supported configuration parameters. 2657 configuration = lakefs_client.Configuration( 2658 host = "http://localhost/api/v1" 2659 ) 2660 2661 # The client must configure the authentication and authorization parameters 2662 # in accordance with the API server security policy. 2663 # Examples for each auth method are provided below, use the example that 2664 # satisfies your auth use case. 2665 2666 # Configure HTTP basic authorization: basic_auth 2667 configuration = lakefs_client.Configuration( 2668 username = 'YOUR_USERNAME', 2669 password = 'YOUR_PASSWORD' 2670 ) 2671 2672 # Configure API key authorization: cookie_auth 2673 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 2674 2675 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 2676 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 2677 2678 # Configure Bearer authorization (JWT): jwt_token 2679 configuration = lakefs_client.Configuration( 2680 access_token = 'YOUR_BEARER_TOKEN' 2681 ) 2682 2683 # Configure API key authorization: oidc_auth 2684 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 2685 2686 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 2687 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 2688 2689 # Configure API key authorization: saml_auth 2690 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 2691 2692 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 2693 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 2694 2695 # Enter a context with an instance of the API client 2696 with lakefs_client.ApiClient(configuration) as api_client: 2697 # Create an instance of the API class 2698 api_instance = auth_api.AuthApi(api_client) 2699 group_id = "groupId_example" # str | 2700 prefix = "prefix_example" # str | return items prefixed with this value (optional) 2701 after = "after_example" # str | return items after this value (optional) 2702 amount = 100 # int | how many items to return (optional) if omitted the server will use the default value of 100 2703 2704 # example passing only required values which don't have defaults set 2705 try: 2706 # list group members 2707 api_response = api_instance.list_group_members(group_id) 2708 pprint(api_response) 2709 except lakefs_client.ApiException as e: 2710 print("Exception when calling AuthApi->list_group_members: %s\n" % e) 2711 2712 # example passing only required values which don't have defaults set 2713 # and optional values 2714 try: 2715 # list group members 2716 api_response = api_instance.list_group_members(group_id, prefix=prefix, after=after, amount=amount) 2717 pprint(api_response) 2718 except lakefs_client.ApiException as e: 2719 print("Exception when calling AuthApi->list_group_members: %s\n" % e) 2720 ``` 2721 2722 2723 ### Parameters 2724 2725 Name | Type | Description | Notes 2726 ------------- | ------------- | ------------- | ------------- 2727 **group_id** | **str**| | 2728 **prefix** | **str**| return items prefixed with this value | [optional] 2729 **after** | **str**| return items after this value | [optional] 2730 **amount** | **int**| how many items to return | [optional] if omitted the server will use the default value of 100 2731 2732 ### Return type 2733 2734 [**UserList**](UserList.md) 2735 2736 ### Authorization 2737 2738 [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) 2739 2740 ### HTTP request headers 2741 2742 - **Content-Type**: Not defined 2743 - **Accept**: application/json 2744 2745 2746 ### HTTP response details 2747 2748 | Status code | Description | Response headers | 2749 |-------------|-------------|------------------| 2750 **200** | group member list | - | 2751 **401** | Unauthorized | - | 2752 **420** | too many requests | - | 2753 **0** | Internal Server Error | - | 2754 2755 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 2756 2757 # **list_group_policies** 2758 > PolicyList list_group_policies(group_id) 2759 2760 list group policies 2761 2762 ### Example 2763 2764 * Basic Authentication (basic_auth): 2765 * Api Key Authentication (cookie_auth): 2766 * Bearer (JWT) Authentication (jwt_token): 2767 * Api Key Authentication (oidc_auth): 2768 * Api Key Authentication (saml_auth): 2769 2770 ```python 2771 import time 2772 import lakefs_client 2773 from lakefs_client.api import auth_api 2774 from lakefs_client.model.policy_list import PolicyList 2775 from lakefs_client.model.error import Error 2776 from pprint import pprint 2777 # Defining the host is optional and defaults to http://localhost/api/v1 2778 # See configuration.py for a list of all supported configuration parameters. 2779 configuration = lakefs_client.Configuration( 2780 host = "http://localhost/api/v1" 2781 ) 2782 2783 # The client must configure the authentication and authorization parameters 2784 # in accordance with the API server security policy. 2785 # Examples for each auth method are provided below, use the example that 2786 # satisfies your auth use case. 2787 2788 # Configure HTTP basic authorization: basic_auth 2789 configuration = lakefs_client.Configuration( 2790 username = 'YOUR_USERNAME', 2791 password = 'YOUR_PASSWORD' 2792 ) 2793 2794 # Configure API key authorization: cookie_auth 2795 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 2796 2797 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 2798 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 2799 2800 # Configure Bearer authorization (JWT): jwt_token 2801 configuration = lakefs_client.Configuration( 2802 access_token = 'YOUR_BEARER_TOKEN' 2803 ) 2804 2805 # Configure API key authorization: oidc_auth 2806 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 2807 2808 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 2809 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 2810 2811 # Configure API key authorization: saml_auth 2812 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 2813 2814 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 2815 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 2816 2817 # Enter a context with an instance of the API client 2818 with lakefs_client.ApiClient(configuration) as api_client: 2819 # Create an instance of the API class 2820 api_instance = auth_api.AuthApi(api_client) 2821 group_id = "groupId_example" # str | 2822 prefix = "prefix_example" # str | return items prefixed with this value (optional) 2823 after = "after_example" # str | return items after this value (optional) 2824 amount = 100 # int | how many items to return (optional) if omitted the server will use the default value of 100 2825 2826 # example passing only required values which don't have defaults set 2827 try: 2828 # list group policies 2829 api_response = api_instance.list_group_policies(group_id) 2830 pprint(api_response) 2831 except lakefs_client.ApiException as e: 2832 print("Exception when calling AuthApi->list_group_policies: %s\n" % e) 2833 2834 # example passing only required values which don't have defaults set 2835 # and optional values 2836 try: 2837 # list group policies 2838 api_response = api_instance.list_group_policies(group_id, prefix=prefix, after=after, amount=amount) 2839 pprint(api_response) 2840 except lakefs_client.ApiException as e: 2841 print("Exception when calling AuthApi->list_group_policies: %s\n" % e) 2842 ``` 2843 2844 2845 ### Parameters 2846 2847 Name | Type | Description | Notes 2848 ------------- | ------------- | ------------- | ------------- 2849 **group_id** | **str**| | 2850 **prefix** | **str**| return items prefixed with this value | [optional] 2851 **after** | **str**| return items after this value | [optional] 2852 **amount** | **int**| how many items to return | [optional] if omitted the server will use the default value of 100 2853 2854 ### Return type 2855 2856 [**PolicyList**](PolicyList.md) 2857 2858 ### Authorization 2859 2860 [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) 2861 2862 ### HTTP request headers 2863 2864 - **Content-Type**: Not defined 2865 - **Accept**: application/json 2866 2867 2868 ### HTTP response details 2869 2870 | Status code | Description | Response headers | 2871 |-------------|-------------|------------------| 2872 **200** | policy list | - | 2873 **401** | Unauthorized | - | 2874 **404** | Resource Not Found | - | 2875 **420** | too many requests | - | 2876 **0** | Internal Server Error | - | 2877 2878 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 2879 2880 # **list_groups** 2881 > GroupList list_groups() 2882 2883 list groups 2884 2885 ### Example 2886 2887 * Basic Authentication (basic_auth): 2888 * Api Key Authentication (cookie_auth): 2889 * Bearer (JWT) Authentication (jwt_token): 2890 * Api Key Authentication (oidc_auth): 2891 * Api Key Authentication (saml_auth): 2892 2893 ```python 2894 import time 2895 import lakefs_client 2896 from lakefs_client.api import auth_api 2897 from lakefs_client.model.group_list import GroupList 2898 from lakefs_client.model.error import Error 2899 from pprint import pprint 2900 # Defining the host is optional and defaults to http://localhost/api/v1 2901 # See configuration.py for a list of all supported configuration parameters. 2902 configuration = lakefs_client.Configuration( 2903 host = "http://localhost/api/v1" 2904 ) 2905 2906 # The client must configure the authentication and authorization parameters 2907 # in accordance with the API server security policy. 2908 # Examples for each auth method are provided below, use the example that 2909 # satisfies your auth use case. 2910 2911 # Configure HTTP basic authorization: basic_auth 2912 configuration = lakefs_client.Configuration( 2913 username = 'YOUR_USERNAME', 2914 password = 'YOUR_PASSWORD' 2915 ) 2916 2917 # Configure API key authorization: cookie_auth 2918 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 2919 2920 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 2921 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 2922 2923 # Configure Bearer authorization (JWT): jwt_token 2924 configuration = lakefs_client.Configuration( 2925 access_token = 'YOUR_BEARER_TOKEN' 2926 ) 2927 2928 # Configure API key authorization: oidc_auth 2929 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 2930 2931 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 2932 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 2933 2934 # Configure API key authorization: saml_auth 2935 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 2936 2937 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 2938 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 2939 2940 # Enter a context with an instance of the API client 2941 with lakefs_client.ApiClient(configuration) as api_client: 2942 # Create an instance of the API class 2943 api_instance = auth_api.AuthApi(api_client) 2944 prefix = "prefix_example" # str | return items prefixed with this value (optional) 2945 after = "after_example" # str | return items after this value (optional) 2946 amount = 100 # int | how many items to return (optional) if omitted the server will use the default value of 100 2947 2948 # example passing only required values which don't have defaults set 2949 # and optional values 2950 try: 2951 # list groups 2952 api_response = api_instance.list_groups(prefix=prefix, after=after, amount=amount) 2953 pprint(api_response) 2954 except lakefs_client.ApiException as e: 2955 print("Exception when calling AuthApi->list_groups: %s\n" % e) 2956 ``` 2957 2958 2959 ### Parameters 2960 2961 Name | Type | Description | Notes 2962 ------------- | ------------- | ------------- | ------------- 2963 **prefix** | **str**| return items prefixed with this value | [optional] 2964 **after** | **str**| return items after this value | [optional] 2965 **amount** | **int**| how many items to return | [optional] if omitted the server will use the default value of 100 2966 2967 ### Return type 2968 2969 [**GroupList**](GroupList.md) 2970 2971 ### Authorization 2972 2973 [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) 2974 2975 ### HTTP request headers 2976 2977 - **Content-Type**: Not defined 2978 - **Accept**: application/json 2979 2980 2981 ### HTTP response details 2982 2983 | Status code | Description | Response headers | 2984 |-------------|-------------|------------------| 2985 **200** | group list | - | 2986 **401** | Unauthorized | - | 2987 **420** | too many requests | - | 2988 **0** | Internal Server Error | - | 2989 2990 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 2991 2992 # **list_policies** 2993 > PolicyList list_policies() 2994 2995 list policies 2996 2997 ### Example 2998 2999 * Basic Authentication (basic_auth): 3000 * Api Key Authentication (cookie_auth): 3001 * Bearer (JWT) Authentication (jwt_token): 3002 * Api Key Authentication (oidc_auth): 3003 * Api Key Authentication (saml_auth): 3004 3005 ```python 3006 import time 3007 import lakefs_client 3008 from lakefs_client.api import auth_api 3009 from lakefs_client.model.policy_list import PolicyList 3010 from lakefs_client.model.error import Error 3011 from pprint import pprint 3012 # Defining the host is optional and defaults to http://localhost/api/v1 3013 # See configuration.py for a list of all supported configuration parameters. 3014 configuration = lakefs_client.Configuration( 3015 host = "http://localhost/api/v1" 3016 ) 3017 3018 # The client must configure the authentication and authorization parameters 3019 # in accordance with the API server security policy. 3020 # Examples for each auth method are provided below, use the example that 3021 # satisfies your auth use case. 3022 3023 # Configure HTTP basic authorization: basic_auth 3024 configuration = lakefs_client.Configuration( 3025 username = 'YOUR_USERNAME', 3026 password = 'YOUR_PASSWORD' 3027 ) 3028 3029 # Configure API key authorization: cookie_auth 3030 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 3031 3032 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 3033 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 3034 3035 # Configure Bearer authorization (JWT): jwt_token 3036 configuration = lakefs_client.Configuration( 3037 access_token = 'YOUR_BEARER_TOKEN' 3038 ) 3039 3040 # Configure API key authorization: oidc_auth 3041 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 3042 3043 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 3044 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 3045 3046 # Configure API key authorization: saml_auth 3047 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 3048 3049 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 3050 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 3051 3052 # Enter a context with an instance of the API client 3053 with lakefs_client.ApiClient(configuration) as api_client: 3054 # Create an instance of the API class 3055 api_instance = auth_api.AuthApi(api_client) 3056 prefix = "prefix_example" # str | return items prefixed with this value (optional) 3057 after = "after_example" # str | return items after this value (optional) 3058 amount = 100 # int | how many items to return (optional) if omitted the server will use the default value of 100 3059 3060 # example passing only required values which don't have defaults set 3061 # and optional values 3062 try: 3063 # list policies 3064 api_response = api_instance.list_policies(prefix=prefix, after=after, amount=amount) 3065 pprint(api_response) 3066 except lakefs_client.ApiException as e: 3067 print("Exception when calling AuthApi->list_policies: %s\n" % e) 3068 ``` 3069 3070 3071 ### Parameters 3072 3073 Name | Type | Description | Notes 3074 ------------- | ------------- | ------------- | ------------- 3075 **prefix** | **str**| return items prefixed with this value | [optional] 3076 **after** | **str**| return items after this value | [optional] 3077 **amount** | **int**| how many items to return | [optional] if omitted the server will use the default value of 100 3078 3079 ### Return type 3080 3081 [**PolicyList**](PolicyList.md) 3082 3083 ### Authorization 3084 3085 [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) 3086 3087 ### HTTP request headers 3088 3089 - **Content-Type**: Not defined 3090 - **Accept**: application/json 3091 3092 3093 ### HTTP response details 3094 3095 | Status code | Description | Response headers | 3096 |-------------|-------------|------------------| 3097 **200** | policy list | - | 3098 **401** | Unauthorized | - | 3099 **420** | too many requests | - | 3100 **0** | Internal Server Error | - | 3101 3102 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 3103 3104 # **list_user_credentials** 3105 > CredentialsList list_user_credentials(user_id) 3106 3107 list user credentials 3108 3109 ### Example 3110 3111 * Basic Authentication (basic_auth): 3112 * Api Key Authentication (cookie_auth): 3113 * Bearer (JWT) Authentication (jwt_token): 3114 * Api Key Authentication (oidc_auth): 3115 * Api Key Authentication (saml_auth): 3116 3117 ```python 3118 import time 3119 import lakefs_client 3120 from lakefs_client.api import auth_api 3121 from lakefs_client.model.error import Error 3122 from lakefs_client.model.credentials_list import CredentialsList 3123 from pprint import pprint 3124 # Defining the host is optional and defaults to http://localhost/api/v1 3125 # See configuration.py for a list of all supported configuration parameters. 3126 configuration = lakefs_client.Configuration( 3127 host = "http://localhost/api/v1" 3128 ) 3129 3130 # The client must configure the authentication and authorization parameters 3131 # in accordance with the API server security policy. 3132 # Examples for each auth method are provided below, use the example that 3133 # satisfies your auth use case. 3134 3135 # Configure HTTP basic authorization: basic_auth 3136 configuration = lakefs_client.Configuration( 3137 username = 'YOUR_USERNAME', 3138 password = 'YOUR_PASSWORD' 3139 ) 3140 3141 # Configure API key authorization: cookie_auth 3142 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 3143 3144 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 3145 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 3146 3147 # Configure Bearer authorization (JWT): jwt_token 3148 configuration = lakefs_client.Configuration( 3149 access_token = 'YOUR_BEARER_TOKEN' 3150 ) 3151 3152 # Configure API key authorization: oidc_auth 3153 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 3154 3155 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 3156 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 3157 3158 # Configure API key authorization: saml_auth 3159 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 3160 3161 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 3162 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 3163 3164 # Enter a context with an instance of the API client 3165 with lakefs_client.ApiClient(configuration) as api_client: 3166 # Create an instance of the API class 3167 api_instance = auth_api.AuthApi(api_client) 3168 user_id = "userId_example" # str | 3169 prefix = "prefix_example" # str | return items prefixed with this value (optional) 3170 after = "after_example" # str | return items after this value (optional) 3171 amount = 100 # int | how many items to return (optional) if omitted the server will use the default value of 100 3172 3173 # example passing only required values which don't have defaults set 3174 try: 3175 # list user credentials 3176 api_response = api_instance.list_user_credentials(user_id) 3177 pprint(api_response) 3178 except lakefs_client.ApiException as e: 3179 print("Exception when calling AuthApi->list_user_credentials: %s\n" % e) 3180 3181 # example passing only required values which don't have defaults set 3182 # and optional values 3183 try: 3184 # list user credentials 3185 api_response = api_instance.list_user_credentials(user_id, prefix=prefix, after=after, amount=amount) 3186 pprint(api_response) 3187 except lakefs_client.ApiException as e: 3188 print("Exception when calling AuthApi->list_user_credentials: %s\n" % e) 3189 ``` 3190 3191 3192 ### Parameters 3193 3194 Name | Type | Description | Notes 3195 ------------- | ------------- | ------------- | ------------- 3196 **user_id** | **str**| | 3197 **prefix** | **str**| return items prefixed with this value | [optional] 3198 **after** | **str**| return items after this value | [optional] 3199 **amount** | **int**| how many items to return | [optional] if omitted the server will use the default value of 100 3200 3201 ### Return type 3202 3203 [**CredentialsList**](CredentialsList.md) 3204 3205 ### Authorization 3206 3207 [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) 3208 3209 ### HTTP request headers 3210 3211 - **Content-Type**: Not defined 3212 - **Accept**: application/json 3213 3214 3215 ### HTTP response details 3216 3217 | Status code | Description | Response headers | 3218 |-------------|-------------|------------------| 3219 **200** | credential list | - | 3220 **401** | Unauthorized | - | 3221 **404** | Resource Not Found | - | 3222 **420** | too many requests | - | 3223 **0** | Internal Server Error | - | 3224 3225 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 3226 3227 # **list_user_external_principals** 3228 > ExternalPrincipalList list_user_external_principals(user_id) 3229 3230 list user external policies attached to a user 3231 3232 ### Example 3233 3234 * Basic Authentication (basic_auth): 3235 * Api Key Authentication (cookie_auth): 3236 * Bearer (JWT) Authentication (jwt_token): 3237 * Api Key Authentication (oidc_auth): 3238 * Api Key Authentication (saml_auth): 3239 3240 ```python 3241 import time 3242 import lakefs_client 3243 from lakefs_client.api import auth_api 3244 from lakefs_client.model.error import Error 3245 from lakefs_client.model.external_principal_list import ExternalPrincipalList 3246 from pprint import pprint 3247 # Defining the host is optional and defaults to http://localhost/api/v1 3248 # See configuration.py for a list of all supported configuration parameters. 3249 configuration = lakefs_client.Configuration( 3250 host = "http://localhost/api/v1" 3251 ) 3252 3253 # The client must configure the authentication and authorization parameters 3254 # in accordance with the API server security policy. 3255 # Examples for each auth method are provided below, use the example that 3256 # satisfies your auth use case. 3257 3258 # Configure HTTP basic authorization: basic_auth 3259 configuration = lakefs_client.Configuration( 3260 username = 'YOUR_USERNAME', 3261 password = 'YOUR_PASSWORD' 3262 ) 3263 3264 # Configure API key authorization: cookie_auth 3265 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 3266 3267 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 3268 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 3269 3270 # Configure Bearer authorization (JWT): jwt_token 3271 configuration = lakefs_client.Configuration( 3272 access_token = 'YOUR_BEARER_TOKEN' 3273 ) 3274 3275 # Configure API key authorization: oidc_auth 3276 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 3277 3278 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 3279 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 3280 3281 # Configure API key authorization: saml_auth 3282 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 3283 3284 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 3285 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 3286 3287 # Enter a context with an instance of the API client 3288 with lakefs_client.ApiClient(configuration) as api_client: 3289 # Create an instance of the API class 3290 api_instance = auth_api.AuthApi(api_client) 3291 user_id = "userId_example" # str | 3292 prefix = "prefix_example" # str | return items prefixed with this value (optional) 3293 after = "after_example" # str | return items after this value (optional) 3294 amount = 100 # int | how many items to return (optional) if omitted the server will use the default value of 100 3295 3296 # example passing only required values which don't have defaults set 3297 try: 3298 # list user external policies attached to a user 3299 api_response = api_instance.list_user_external_principals(user_id) 3300 pprint(api_response) 3301 except lakefs_client.ApiException as e: 3302 print("Exception when calling AuthApi->list_user_external_principals: %s\n" % e) 3303 3304 # example passing only required values which don't have defaults set 3305 # and optional values 3306 try: 3307 # list user external policies attached to a user 3308 api_response = api_instance.list_user_external_principals(user_id, prefix=prefix, after=after, amount=amount) 3309 pprint(api_response) 3310 except lakefs_client.ApiException as e: 3311 print("Exception when calling AuthApi->list_user_external_principals: %s\n" % e) 3312 ``` 3313 3314 3315 ### Parameters 3316 3317 Name | Type | Description | Notes 3318 ------------- | ------------- | ------------- | ------------- 3319 **user_id** | **str**| | 3320 **prefix** | **str**| return items prefixed with this value | [optional] 3321 **after** | **str**| return items after this value | [optional] 3322 **amount** | **int**| how many items to return | [optional] if omitted the server will use the default value of 100 3323 3324 ### Return type 3325 3326 [**ExternalPrincipalList**](ExternalPrincipalList.md) 3327 3328 ### Authorization 3329 3330 [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) 3331 3332 ### HTTP request headers 3333 3334 - **Content-Type**: Not defined 3335 - **Accept**: application/json 3336 3337 3338 ### HTTP response details 3339 3340 | Status code | Description | Response headers | 3341 |-------------|-------------|------------------| 3342 **200** | external principals list | - | 3343 **401** | Unauthorized | - | 3344 **404** | Resource Not Found | - | 3345 **420** | too many requests | - | 3346 **0** | Internal Server Error | - | 3347 3348 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 3349 3350 # **list_user_groups** 3351 > GroupList list_user_groups(user_id) 3352 3353 list user groups 3354 3355 ### Example 3356 3357 * Basic Authentication (basic_auth): 3358 * Api Key Authentication (cookie_auth): 3359 * Bearer (JWT) Authentication (jwt_token): 3360 * Api Key Authentication (oidc_auth): 3361 * Api Key Authentication (saml_auth): 3362 3363 ```python 3364 import time 3365 import lakefs_client 3366 from lakefs_client.api import auth_api 3367 from lakefs_client.model.group_list import GroupList 3368 from lakefs_client.model.error import Error 3369 from pprint import pprint 3370 # Defining the host is optional and defaults to http://localhost/api/v1 3371 # See configuration.py for a list of all supported configuration parameters. 3372 configuration = lakefs_client.Configuration( 3373 host = "http://localhost/api/v1" 3374 ) 3375 3376 # The client must configure the authentication and authorization parameters 3377 # in accordance with the API server security policy. 3378 # Examples for each auth method are provided below, use the example that 3379 # satisfies your auth use case. 3380 3381 # Configure HTTP basic authorization: basic_auth 3382 configuration = lakefs_client.Configuration( 3383 username = 'YOUR_USERNAME', 3384 password = 'YOUR_PASSWORD' 3385 ) 3386 3387 # Configure API key authorization: cookie_auth 3388 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 3389 3390 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 3391 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 3392 3393 # Configure Bearer authorization (JWT): jwt_token 3394 configuration = lakefs_client.Configuration( 3395 access_token = 'YOUR_BEARER_TOKEN' 3396 ) 3397 3398 # Configure API key authorization: oidc_auth 3399 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 3400 3401 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 3402 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 3403 3404 # Configure API key authorization: saml_auth 3405 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 3406 3407 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 3408 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 3409 3410 # Enter a context with an instance of the API client 3411 with lakefs_client.ApiClient(configuration) as api_client: 3412 # Create an instance of the API class 3413 api_instance = auth_api.AuthApi(api_client) 3414 user_id = "userId_example" # str | 3415 prefix = "prefix_example" # str | return items prefixed with this value (optional) 3416 after = "after_example" # str | return items after this value (optional) 3417 amount = 100 # int | how many items to return (optional) if omitted the server will use the default value of 100 3418 3419 # example passing only required values which don't have defaults set 3420 try: 3421 # list user groups 3422 api_response = api_instance.list_user_groups(user_id) 3423 pprint(api_response) 3424 except lakefs_client.ApiException as e: 3425 print("Exception when calling AuthApi->list_user_groups: %s\n" % e) 3426 3427 # example passing only required values which don't have defaults set 3428 # and optional values 3429 try: 3430 # list user groups 3431 api_response = api_instance.list_user_groups(user_id, prefix=prefix, after=after, amount=amount) 3432 pprint(api_response) 3433 except lakefs_client.ApiException as e: 3434 print("Exception when calling AuthApi->list_user_groups: %s\n" % e) 3435 ``` 3436 3437 3438 ### Parameters 3439 3440 Name | Type | Description | Notes 3441 ------------- | ------------- | ------------- | ------------- 3442 **user_id** | **str**| | 3443 **prefix** | **str**| return items prefixed with this value | [optional] 3444 **after** | **str**| return items after this value | [optional] 3445 **amount** | **int**| how many items to return | [optional] if omitted the server will use the default value of 100 3446 3447 ### Return type 3448 3449 [**GroupList**](GroupList.md) 3450 3451 ### Authorization 3452 3453 [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) 3454 3455 ### HTTP request headers 3456 3457 - **Content-Type**: Not defined 3458 - **Accept**: application/json 3459 3460 3461 ### HTTP response details 3462 3463 | Status code | Description | Response headers | 3464 |-------------|-------------|------------------| 3465 **200** | group list | - | 3466 **401** | Unauthorized | - | 3467 **404** | Resource Not Found | - | 3468 **420** | too many requests | - | 3469 **0** | Internal Server Error | - | 3470 3471 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 3472 3473 # **list_user_policies** 3474 > PolicyList list_user_policies(user_id) 3475 3476 list user policies 3477 3478 ### Example 3479 3480 * Basic Authentication (basic_auth): 3481 * Api Key Authentication (cookie_auth): 3482 * Bearer (JWT) Authentication (jwt_token): 3483 * Api Key Authentication (oidc_auth): 3484 * Api Key Authentication (saml_auth): 3485 3486 ```python 3487 import time 3488 import lakefs_client 3489 from lakefs_client.api import auth_api 3490 from lakefs_client.model.policy_list import PolicyList 3491 from lakefs_client.model.error import Error 3492 from pprint import pprint 3493 # Defining the host is optional and defaults to http://localhost/api/v1 3494 # See configuration.py for a list of all supported configuration parameters. 3495 configuration = lakefs_client.Configuration( 3496 host = "http://localhost/api/v1" 3497 ) 3498 3499 # The client must configure the authentication and authorization parameters 3500 # in accordance with the API server security policy. 3501 # Examples for each auth method are provided below, use the example that 3502 # satisfies your auth use case. 3503 3504 # Configure HTTP basic authorization: basic_auth 3505 configuration = lakefs_client.Configuration( 3506 username = 'YOUR_USERNAME', 3507 password = 'YOUR_PASSWORD' 3508 ) 3509 3510 # Configure API key authorization: cookie_auth 3511 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 3512 3513 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 3514 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 3515 3516 # Configure Bearer authorization (JWT): jwt_token 3517 configuration = lakefs_client.Configuration( 3518 access_token = 'YOUR_BEARER_TOKEN' 3519 ) 3520 3521 # Configure API key authorization: oidc_auth 3522 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 3523 3524 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 3525 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 3526 3527 # Configure API key authorization: saml_auth 3528 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 3529 3530 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 3531 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 3532 3533 # Enter a context with an instance of the API client 3534 with lakefs_client.ApiClient(configuration) as api_client: 3535 # Create an instance of the API class 3536 api_instance = auth_api.AuthApi(api_client) 3537 user_id = "userId_example" # str | 3538 prefix = "prefix_example" # str | return items prefixed with this value (optional) 3539 after = "after_example" # str | return items after this value (optional) 3540 amount = 100 # int | how many items to return (optional) if omitted the server will use the default value of 100 3541 effective = False # bool | will return all distinct policies attached to the user or any of its groups (optional) if omitted the server will use the default value of False 3542 3543 # example passing only required values which don't have defaults set 3544 try: 3545 # list user policies 3546 api_response = api_instance.list_user_policies(user_id) 3547 pprint(api_response) 3548 except lakefs_client.ApiException as e: 3549 print("Exception when calling AuthApi->list_user_policies: %s\n" % e) 3550 3551 # example passing only required values which don't have defaults set 3552 # and optional values 3553 try: 3554 # list user policies 3555 api_response = api_instance.list_user_policies(user_id, prefix=prefix, after=after, amount=amount, effective=effective) 3556 pprint(api_response) 3557 except lakefs_client.ApiException as e: 3558 print("Exception when calling AuthApi->list_user_policies: %s\n" % e) 3559 ``` 3560 3561 3562 ### Parameters 3563 3564 Name | Type | Description | Notes 3565 ------------- | ------------- | ------------- | ------------- 3566 **user_id** | **str**| | 3567 **prefix** | **str**| return items prefixed with this value | [optional] 3568 **after** | **str**| return items after this value | [optional] 3569 **amount** | **int**| how many items to return | [optional] if omitted the server will use the default value of 100 3570 **effective** | **bool**| will return all distinct policies attached to the user or any of its groups | [optional] if omitted the server will use the default value of False 3571 3572 ### Return type 3573 3574 [**PolicyList**](PolicyList.md) 3575 3576 ### Authorization 3577 3578 [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) 3579 3580 ### HTTP request headers 3581 3582 - **Content-Type**: Not defined 3583 - **Accept**: application/json 3584 3585 3586 ### HTTP response details 3587 3588 | Status code | Description | Response headers | 3589 |-------------|-------------|------------------| 3590 **200** | policy list | - | 3591 **401** | Unauthorized | - | 3592 **404** | Resource Not Found | - | 3593 **420** | too many requests | - | 3594 **0** | Internal Server Error | - | 3595 3596 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 3597 3598 # **list_users** 3599 > UserList list_users() 3600 3601 list users 3602 3603 ### Example 3604 3605 * Basic Authentication (basic_auth): 3606 * Api Key Authentication (cookie_auth): 3607 * Bearer (JWT) Authentication (jwt_token): 3608 * Api Key Authentication (oidc_auth): 3609 * Api Key Authentication (saml_auth): 3610 3611 ```python 3612 import time 3613 import lakefs_client 3614 from lakefs_client.api import auth_api 3615 from lakefs_client.model.user_list import UserList 3616 from lakefs_client.model.error import Error 3617 from pprint import pprint 3618 # Defining the host is optional and defaults to http://localhost/api/v1 3619 # See configuration.py for a list of all supported configuration parameters. 3620 configuration = lakefs_client.Configuration( 3621 host = "http://localhost/api/v1" 3622 ) 3623 3624 # The client must configure the authentication and authorization parameters 3625 # in accordance with the API server security policy. 3626 # Examples for each auth method are provided below, use the example that 3627 # satisfies your auth use case. 3628 3629 # Configure HTTP basic authorization: basic_auth 3630 configuration = lakefs_client.Configuration( 3631 username = 'YOUR_USERNAME', 3632 password = 'YOUR_PASSWORD' 3633 ) 3634 3635 # Configure API key authorization: cookie_auth 3636 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 3637 3638 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 3639 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 3640 3641 # Configure Bearer authorization (JWT): jwt_token 3642 configuration = lakefs_client.Configuration( 3643 access_token = 'YOUR_BEARER_TOKEN' 3644 ) 3645 3646 # Configure API key authorization: oidc_auth 3647 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 3648 3649 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 3650 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 3651 3652 # Configure API key authorization: saml_auth 3653 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 3654 3655 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 3656 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 3657 3658 # Enter a context with an instance of the API client 3659 with lakefs_client.ApiClient(configuration) as api_client: 3660 # Create an instance of the API class 3661 api_instance = auth_api.AuthApi(api_client) 3662 prefix = "prefix_example" # str | return items prefixed with this value (optional) 3663 after = "after_example" # str | return items after this value (optional) 3664 amount = 100 # int | how many items to return (optional) if omitted the server will use the default value of 100 3665 3666 # example passing only required values which don't have defaults set 3667 # and optional values 3668 try: 3669 # list users 3670 api_response = api_instance.list_users(prefix=prefix, after=after, amount=amount) 3671 pprint(api_response) 3672 except lakefs_client.ApiException as e: 3673 print("Exception when calling AuthApi->list_users: %s\n" % e) 3674 ``` 3675 3676 3677 ### Parameters 3678 3679 Name | Type | Description | Notes 3680 ------------- | ------------- | ------------- | ------------- 3681 **prefix** | **str**| return items prefixed with this value | [optional] 3682 **after** | **str**| return items after this value | [optional] 3683 **amount** | **int**| how many items to return | [optional] if omitted the server will use the default value of 100 3684 3685 ### Return type 3686 3687 [**UserList**](UserList.md) 3688 3689 ### Authorization 3690 3691 [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) 3692 3693 ### HTTP request headers 3694 3695 - **Content-Type**: Not defined 3696 - **Accept**: application/json 3697 3698 3699 ### HTTP response details 3700 3701 | Status code | Description | Response headers | 3702 |-------------|-------------|------------------| 3703 **200** | user list | - | 3704 **401** | Unauthorized | - | 3705 **420** | too many requests | - | 3706 **0** | Internal Server Error | - | 3707 3708 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 3709 3710 # **login** 3711 > AuthenticationToken login() 3712 3713 perform a login 3714 3715 ### Example 3716 3717 3718 ```python 3719 import time 3720 import lakefs_client 3721 from lakefs_client.api import auth_api 3722 from lakefs_client.model.authentication_token import AuthenticationToken 3723 from lakefs_client.model.login_information import LoginInformation 3724 from lakefs_client.model.error import Error 3725 from pprint import pprint 3726 # Defining the host is optional and defaults to http://localhost/api/v1 3727 # See configuration.py for a list of all supported configuration parameters. 3728 configuration = lakefs_client.Configuration( 3729 host = "http://localhost/api/v1" 3730 ) 3731 3732 3733 # Enter a context with an instance of the API client 3734 with lakefs_client.ApiClient() as api_client: 3735 # Create an instance of the API class 3736 api_instance = auth_api.AuthApi(api_client) 3737 login_information = LoginInformation( 3738 access_key_id="access_key_id_example", 3739 secret_access_key="secret_access_key_example", 3740 ) # LoginInformation | (optional) 3741 3742 # example passing only required values which don't have defaults set 3743 # and optional values 3744 try: 3745 # perform a login 3746 api_response = api_instance.login(login_information=login_information) 3747 pprint(api_response) 3748 except lakefs_client.ApiException as e: 3749 print("Exception when calling AuthApi->login: %s\n" % e) 3750 ``` 3751 3752 3753 ### Parameters 3754 3755 Name | Type | Description | Notes 3756 ------------- | ------------- | ------------- | ------------- 3757 **login_information** | [**LoginInformation**](LoginInformation.md)| | [optional] 3758 3759 ### Return type 3760 3761 [**AuthenticationToken**](AuthenticationToken.md) 3762 3763 ### Authorization 3764 3765 No authorization required 3766 3767 ### HTTP request headers 3768 3769 - **Content-Type**: application/json 3770 - **Accept**: application/json 3771 3772 3773 ### HTTP response details 3774 3775 | Status code | Description | Response headers | 3776 |-------------|-------------|------------------| 3777 **200** | successful login | * Set-Cookie - <br> | 3778 **401** | Unauthorized | - | 3779 **420** | too many requests | - | 3780 **0** | Internal Server Error | - | 3781 3782 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 3783 3784 # **set_group_acl** 3785 > set_group_acl(group_id, acl) 3786 3787 set ACL of group 3788 3789 ### Example 3790 3791 * Basic Authentication (basic_auth): 3792 * Api Key Authentication (cookie_auth): 3793 * Bearer (JWT) Authentication (jwt_token): 3794 * Api Key Authentication (oidc_auth): 3795 * Api Key Authentication (saml_auth): 3796 3797 ```python 3798 import time 3799 import lakefs_client 3800 from lakefs_client.api import auth_api 3801 from lakefs_client.model.acl import ACL 3802 from lakefs_client.model.error import Error 3803 from pprint import pprint 3804 # Defining the host is optional and defaults to http://localhost/api/v1 3805 # See configuration.py for a list of all supported configuration parameters. 3806 configuration = lakefs_client.Configuration( 3807 host = "http://localhost/api/v1" 3808 ) 3809 3810 # The client must configure the authentication and authorization parameters 3811 # in accordance with the API server security policy. 3812 # Examples for each auth method are provided below, use the example that 3813 # satisfies your auth use case. 3814 3815 # Configure HTTP basic authorization: basic_auth 3816 configuration = lakefs_client.Configuration( 3817 username = 'YOUR_USERNAME', 3818 password = 'YOUR_PASSWORD' 3819 ) 3820 3821 # Configure API key authorization: cookie_auth 3822 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 3823 3824 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 3825 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 3826 3827 # Configure Bearer authorization (JWT): jwt_token 3828 configuration = lakefs_client.Configuration( 3829 access_token = 'YOUR_BEARER_TOKEN' 3830 ) 3831 3832 # Configure API key authorization: oidc_auth 3833 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 3834 3835 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 3836 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 3837 3838 # Configure API key authorization: saml_auth 3839 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 3840 3841 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 3842 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 3843 3844 # Enter a context with an instance of the API client 3845 with lakefs_client.ApiClient(configuration) as api_client: 3846 # Create an instance of the API class 3847 api_instance = auth_api.AuthApi(api_client) 3848 group_id = "groupId_example" # str | 3849 acl = ACL( 3850 permission="permission_example", 3851 ) # ACL | 3852 3853 # example passing only required values which don't have defaults set 3854 try: 3855 # set ACL of group 3856 api_instance.set_group_acl(group_id, acl) 3857 except lakefs_client.ApiException as e: 3858 print("Exception when calling AuthApi->set_group_acl: %s\n" % e) 3859 ``` 3860 3861 3862 ### Parameters 3863 3864 Name | Type | Description | Notes 3865 ------------- | ------------- | ------------- | ------------- 3866 **group_id** | **str**| | 3867 **acl** | [**ACL**](ACL.md)| | 3868 3869 ### Return type 3870 3871 void (empty response body) 3872 3873 ### Authorization 3874 3875 [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) 3876 3877 ### HTTP request headers 3878 3879 - **Content-Type**: application/json 3880 - **Accept**: application/json 3881 3882 3883 ### HTTP response details 3884 3885 | Status code | Description | Response headers | 3886 |-------------|-------------|------------------| 3887 **201** | ACL successfully changed | - | 3888 **401** | Unauthorized | - | 3889 **404** | Resource Not Found | - | 3890 **420** | too many requests | - | 3891 **0** | Internal Server Error | - | 3892 3893 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 3894 3895 # **update_policy** 3896 > Policy update_policy(policy_id, policy) 3897 3898 update policy 3899 3900 ### Example 3901 3902 * Basic Authentication (basic_auth): 3903 * Api Key Authentication (cookie_auth): 3904 * Bearer (JWT) Authentication (jwt_token): 3905 * Api Key Authentication (oidc_auth): 3906 * Api Key Authentication (saml_auth): 3907 3908 ```python 3909 import time 3910 import lakefs_client 3911 from lakefs_client.api import auth_api 3912 from lakefs_client.model.policy import Policy 3913 from lakefs_client.model.error import Error 3914 from pprint import pprint 3915 # Defining the host is optional and defaults to http://localhost/api/v1 3916 # See configuration.py for a list of all supported configuration parameters. 3917 configuration = lakefs_client.Configuration( 3918 host = "http://localhost/api/v1" 3919 ) 3920 3921 # The client must configure the authentication and authorization parameters 3922 # in accordance with the API server security policy. 3923 # Examples for each auth method are provided below, use the example that 3924 # satisfies your auth use case. 3925 3926 # Configure HTTP basic authorization: basic_auth 3927 configuration = lakefs_client.Configuration( 3928 username = 'YOUR_USERNAME', 3929 password = 'YOUR_PASSWORD' 3930 ) 3931 3932 # Configure API key authorization: cookie_auth 3933 configuration.api_key['cookie_auth'] = 'YOUR_API_KEY' 3934 3935 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 3936 # configuration.api_key_prefix['cookie_auth'] = 'Bearer' 3937 3938 # Configure Bearer authorization (JWT): jwt_token 3939 configuration = lakefs_client.Configuration( 3940 access_token = 'YOUR_BEARER_TOKEN' 3941 ) 3942 3943 # Configure API key authorization: oidc_auth 3944 configuration.api_key['oidc_auth'] = 'YOUR_API_KEY' 3945 3946 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 3947 # configuration.api_key_prefix['oidc_auth'] = 'Bearer' 3948 3949 # Configure API key authorization: saml_auth 3950 configuration.api_key['saml_auth'] = 'YOUR_API_KEY' 3951 3952 # Uncomment below to setup prefix (e.g. Bearer) for API key, if needed 3953 # configuration.api_key_prefix['saml_auth'] = 'Bearer' 3954 3955 # Enter a context with an instance of the API client 3956 with lakefs_client.ApiClient(configuration) as api_client: 3957 # Create an instance of the API class 3958 api_instance = auth_api.AuthApi(api_client) 3959 policy_id = "policyId_example" # str | 3960 policy = Policy( 3961 id="id_example", 3962 creation_date=1, 3963 statement=[ 3964 Statement( 3965 effect="allow", 3966 resource="resource_example", 3967 action=[ 3968 "action_example", 3969 ], 3970 ), 3971 ], 3972 ) # Policy | 3973 3974 # example passing only required values which don't have defaults set 3975 try: 3976 # update policy 3977 api_response = api_instance.update_policy(policy_id, policy) 3978 pprint(api_response) 3979 except lakefs_client.ApiException as e: 3980 print("Exception when calling AuthApi->update_policy: %s\n" % e) 3981 ``` 3982 3983 3984 ### Parameters 3985 3986 Name | Type | Description | Notes 3987 ------------- | ------------- | ------------- | ------------- 3988 **policy_id** | **str**| | 3989 **policy** | [**Policy**](Policy.md)| | 3990 3991 ### Return type 3992 3993 [**Policy**](Policy.md) 3994 3995 ### Authorization 3996 3997 [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) 3998 3999 ### HTTP request headers 4000 4001 - **Content-Type**: application/json 4002 - **Accept**: application/json 4003 4004 4005 ### HTTP response details 4006 4007 | Status code | Description | Response headers | 4008 |-------------|-------------|------------------| 4009 **200** | policy | - | 4010 **400** | Validation Error | - | 4011 **401** | Unauthorized | - | 4012 **404** | Resource Not Found | - | 4013 **420** | too many requests | - | 4014 **0** | Internal Server Error | - | 4015 4016 [[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) 4017