-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpoc-api.openapi.json
1 lines (1 loc) · 6.27 KB
/
poc-api.openapi.json
1
{"openapi":"3.0.1","info":{"title":"OpenAPI definition","version":"v0"},"servers":[{"url":"https://jerome-w:4204","description":"Generated server url"}],"tags":[{"name":"Users","description":"CRUD operations for grants delegation between users"}],"paths":{"/users/{grantingUserSubject}/proxies/granted/{grantedUserSubject}/{id}":{"put":{"tags":["Users"],"description":"Update grant delegation from \"granting user\" to \"granted user\".","operationId":"updateProxy","parameters":[{"name":"grantingUserSubject","in":"path","description":"Proxied user subject","required":true,"schema":{"type":"string"}},{"name":"grantedUserSubject","in":"path","description":"Granted user subject","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","description":"proxy ID","required":true,"schema":{"type":"integer","format":"int64"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProxyEditDto"}}},"required":true},"responses":{"404":{"description":"Not Found"},"409":{"description":"Conflict"},"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object"}},"application/xml":{"schema":{"type":"object"}}}}}},"delete":{"tags":["Users"],"description":"Delete all grants \"granted user\" had to act on behalf of \"granting user\".","operationId":"deleteProxy","parameters":[{"name":"grantingUserSubject","in":"path","description":"Proxied user subject","required":true,"schema":{"type":"string"}},{"name":"grantedUserSubject","in":"path","description":"Granted user subject","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","description":"proxy ID","required":true,"schema":{"type":"integer","format":"int64"}}],"responses":{"404":{"description":"Not Found"},"409":{"description":"Conflict"},"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object"}},"application/xml":{"schema":{"type":"object"}}}}}}},"/users":{"get":{"tags":["Users"],"description":"Retrieve collection of users.","operationId":"retrieveByEmailOrPreferredUsernamePart","parameters":[{"name":"emailOrPreferredUsernamePart","in":"query","description":"Mandatory and min length is 4. Case insensitive part of user e-mail or preferredUserName.","required":true,"schema":{"type":"string"}}],"responses":{"404":{"description":"Not Found"},"409":{"description":"Conflict"},"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/UserDto"}}},"application/xml":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/UserDto"}}}}}}},"post":{"tags":["Users"],"description":"Register a user in proxies service","operationId":"create","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserCreateDto"}}},"required":true},"responses":{"404":{"description":"Not Found"},"409":{"description":"Conflict"},"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object"}},"application/xml":{"schema":{"type":"object"}}}}}}},"/users/{grantingUserSubject}/proxies/granted/{grantedUserSubject}":{"post":{"tags":["Users"],"description":"Create grant delegation from \"granting user\" to \"granted user\".","operationId":"createProxy","parameters":[{"name":"grantingUserSubject","in":"path","description":"Proxied user subject","required":true,"schema":{"type":"string"}},{"name":"grantedUserSubject","in":"path","description":"Granted user subject","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProxyEditDto"}}},"required":true},"responses":{"404":{"description":"Not Found"},"409":{"description":"Conflict"},"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object"}},"application/xml":{"schema":{"type":"object"}}}}}}},"/users/{subject}":{"get":{"tags":["Users"],"description":"Retrieve a user by subject","operationId":"retrieveBySubject","parameters":[{"name":"subject","in":"path","description":"User subject.","required":true,"schema":{"type":"string"}}],"responses":{"404":{"description":"Not Found"},"409":{"description":"Conflict"},"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserDto"}},"application/xml":{"schema":{"$ref":"#/components/schemas/UserDto"}}}}}}},"/users/{subject}/proxies/granting":{"get":{"tags":["Users"],"operationId":"retrieveGrantingProxies","parameters":[{"name":"subject","in":"path","description":"User subject.","required":true,"schema":{"type":"string"}}],"responses":{"404":{"description":"Not Found"},"409":{"description":"Conflict"},"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ProxyDto"}}},"application/xml":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ProxyDto"}}}}}}}},"/users/{subject}/proxies/granted":{"get":{"tags":["Users"],"operationId":"retrieveGrantedProxies","parameters":[{"name":"subject","in":"path","description":"User subject.","required":true,"schema":{"type":"string"}}],"responses":{"404":{"description":"Not Found"},"409":{"description":"Conflict"},"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ProxyDto"}}},"application/xml":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ProxyDto"}}}}}}}}},"components":{"schemas":{"ProxyEditDto":{"required":["grants","start"],"type":"object","properties":{"grants":{"type":"array","items":{"type":"string"}},"start":{"type":"integer","format":"int64"},"end":{"type":"integer","format":"int64"}}},"UserCreateDto":{"required":["email","preferedUsername","subject"],"type":"object","properties":{"subject":{"type":"string"},"email":{"type":"string"},"preferedUsername":{"type":"string"}}},"UserDto":{"required":["email","id","preferedUsername","subject"],"type":"object","properties":{"id":{"type":"integer","format":"int64"},"subject":{"type":"string"},"email":{"type":"string"},"preferedUsername":{"type":"string"}}},"ProxyDto":{"required":["grantedUserSubject","grantingUserSubject","grants","id","start"],"type":"object","properties":{"id":{"type":"integer","format":"int64"},"grantingUserSubject":{"type":"string"},"grantedUserSubject":{"type":"string"},"grants":{"type":"array","items":{"type":"string"}},"start":{"type":"integer","format":"int64"},"end":{"type":"integer","format":"int64"}}}}}}