mirror of
				https://github.com/Unleash/unleash.git
				synced 2025-10-27 11:02:16 +01:00 
			
		
		
		
	docs(4.3): update API access document.
This commit is contained in:
		
							parent
							
								
									bfeb19f5f1
								
							
						
					
					
						commit
						c9ef7c1f44
					
				| @ -11,7 +11,9 @@ Please refer to [Create token](../user_guide/api-token) on how to create an API | ||||
| 
 | ||||
| Please note that it may take up to 60 seconds for the new key to propagate to all Unleash instances due to eager caching. | ||||
| 
 | ||||
| > If you need an API token to use in a client SDK you should create a "client token" as these have less access. | ||||
| :::note | ||||
| If you need an API token to use in a client SDK you should create a "client token" as these have fewer access rights. | ||||
| ::: | ||||
| 
 | ||||
| ## Step 2: Use Admin API {#step-2-use-admin-api} | ||||
| 
 | ||||
| @ -20,12 +22,14 @@ Now that you have an access token with admin privileges we can use that to perfo | ||||
| In the example below we will use the [Unleash Admin API](../api/admin/features) to enable the “Demo” feature toggle using curl. | ||||
| 
 | ||||
| ```sh | ||||
| curl -X POST -H "Content-Type: application/json" -H "Authorization: admintoken" https://app.unleash-hosted.com/demo/api/admin/features/Demo/toggle/on | ||||
| curl -X POST -H "Content-Type: application/json" \ | ||||
|      -H "Authorization: admintoken" \ | ||||
|      https://app.unleash-hosted.com/demo/api/admin/features/Demo/toggle/on | ||||
| ``` | ||||
| 
 | ||||
| **Great success!** We have now enabled the feature toggle. We can also verify that it was actually changed by the API user by navigating to the history (audit log) for this feature toggle. | ||||
| 
 | ||||
|  | ||||
|  | ||||
| 
 | ||||
| ## API overview {#api-overview} | ||||
| 
 | ||||
|  | ||||
										
											Binary file not shown.
										
									
								
							| Before Width: | Height: | Size: 470 KiB After Width: | Height: | Size: 122 KiB | 
		Loading…
	
		Reference in New Issue
	
	Block a user