Features
You must be authenticated to use this resource.
 
Create a new feature
POST /features/
Request
 | curl -X "POST" "http://0.0.0.0:8000/features/" \
     -H 'Authorization: Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9...' \
     -H 'Content-Type: application/json; charset=utf-8' \
     -d '{
            "id": "search-button",
            "enabled": true,
            "deny": false,
            "services": [],
            "version": "1.0.0"
         }'
 
 | 
Response
Get all features
GET /features/
Request
 | curl "http://{host}/features/" \
     -H 'Authorization: Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9...'
 
 | 
Response
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16  | [
  {
    "id": "search-button",
    "version": "1.0.0",
    "enabled": true,
    "deny": false,
    "services": []
  },
  {
    "id": "footer",
    "version": "1.0.1",
    "enabled": true,
    "deny": false,
    "services": []
  },
]
 
 | 
 
 | {"message": "Unauthorized."}
 
 | 
 
 
Get feature by id
GET /features/{id}
Request
 | curl "http://{host}/features/search-button" \
     -H 'Authorization: Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9...'
 
 | 
Response
Update feature
PUT /features/{id}
Request
 | curl -X "PUT" "http://0.0.0.0:8000/features/search-button" \
     -H 'Authorization: Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9...' \
     -H 'Content-Type: application/json; charset=utf-8' \
     -d '{
            "enabled": true,
            "deny": false,
            "services": [1,2],
            "version": "1.0.2"
         }'
 
 | 
Response
Delete feature
DELETE /features/{id}
Request
 | curl "http://0.0.0.0:8000/features/search-button" \
     -H 'Authorization: Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9...'
 
 | 
Response
Feature data
  
    
  
  
    
      | id | 
      String | 
      Feature name. | 
    
    
      | version | 
      String | 
      Feature version. | 
    
    
      | enabled | 
      Bool | 
      If value is true the feature can be used by all services. If value is false only services in services list can be use this feature. | 
    
    
      | deny | 
      Bool | 
      If value is true the feature can be used by all services except the services in services list. | 
    
    
      | services | 
      Array | 
      Services list. |