Skip to content

Commit

Permalink
refactor: remove support for deprecated fields and fix tests (#256)
Browse files Browse the repository at this point in the history
  • Loading branch information
Chief-Rishab committed Jun 8, 2023
1 parent 9f519a3 commit 6c3ac60
Show file tree
Hide file tree
Showing 31 changed files with 2,959 additions and 2,998 deletions.
2 changes: 1 addition & 1 deletion Makefile
Expand Up @@ -4,7 +4,7 @@ TAG := "$(shell git rev-list --tags --max-count=1)"
VERSION := "$(shell git describe --tags ${TAG})"
.PHONY: build check fmt lint test test-race vet test-cover-html help install proto ui
.DEFAULT_GOAL := build
PROTON_COMMIT := "13a222e07cbefed5b480b31f06420e752002877d"
PROTON_COMMIT := "6a3ba5af8fb2e25094520ebe41692339783652e8"

ui:
@echo " > generating ui build"
Expand Down
6 changes: 3 additions & 3 deletions docs/docs/apis/admin-service-create-role.api.mdx

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions docs/docs/apis/admin-service-list-groups.api.mdx

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions docs/docs/apis/shield-service-add-organization-users.api.mdx
Expand Up @@ -5,7 +5,7 @@ description: "Add a user to an organization. A user must exists in Shield before
sidebar_label: "Add organization user"
hide_title: true
hide_table_of_contents: true
api: {"description":"Add a user to an organization. A user must exists in Shield before adding it to an org. This request will fail if the user doesn't exists","operationId":"ShieldService_AddOrganizationUsers","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object"}}}},"400":{"description":"Bad Request - The request was malformed or contained invalid parameters.","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"}},"additionalProperties":{}}}}}}}},"401":{"description":"Unauthorized - Authentication is required","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"}},"additionalProperties":{}}}}}}}},"403":{"description":"Forbidden - User does not have permission to access the resource","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"}},"additionalProperties":{}}}}}}}},"404":{"description":"Not Found - The requested resource was not found","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"}},"additionalProperties":{}}}}}}}},"500":{"description":"Internal Server Error. Returned when theres is something wrong with Shield server.","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"}},"additionalProperties":{}}}}}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"}},"additionalProperties":{}}}}}}}}},"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"userIds":{"type":"array","items":{"type":"string"}}}}}},"required":true},"tags":["Organization"],"method":"post","path":"/v1beta1/organizations/{id}/users","servers":[{"url":"http://127.0.0.1:7400"}],"jsonRequestBodyExample":{"userIds":["string"]},"info":{"title":"Shield Administration API","description":"The Shield APIs adhere to the OpenAPI specification, also known as Swagger, which provides a standardized approach for designing, documenting, and consuming RESTful APIs. With OpenAPI, you gain a clear understanding of the API endpoints, request/response structures, and authentication mechanisms supported by the Shield APIs. By leveraging the OpenAPI specification, developers can easily explore and interact with the Shield APIs using a variety of tools and libraries. The OpenAPI specification enables automatic code generation, interactive API documentation, and seamless integration with API testing frameworks, making it easier than ever to integrate Shield into your existing applications and workflows.","version":"0.2.0","contact":{"name":"Open DataOps Foundation","url":"https://www.odpf.io/","email":"hello@odpf.io"},"license":{"name":"Apache 2.0","url":"https://github.com/odpf/shield/blob/main/LICENSE"}},"postman":{"name":"Add organization user","description":{"content":"Add a user to an organization. A user must exists in Shield before adding it to an org. This request will fail if the user doesn't exists","type":"text/plain"},"url":{"path":["v1beta1","organizations",":id","users"],"host":["{{baseUrl}}"],"query":[],"variable":[{"disabled":false,"description":{"content":"(Required) ","type":"text/plain"},"type":"any","value":"","key":"id"}]},"header":[{"key":"Content-Type","value":"application/json"},{"key":"Accept","value":"application/json"}],"method":"POST","body":{"mode":"raw","raw":"\"\"","options":{"raw":{"language":"json"}}}}}
api: {"description":"Add a user to an organization. A user must exists in Shield before adding it to an org. This request will fail if the user doesn't exists","operationId":"ShieldService_AddOrganizationUsers","responses":{"200":{"description":"A successful response.","content":{"application/json":{"schema":{"type":"object"}}}},"400":{"description":"Bad Request - The request was malformed or contained invalid parameters.","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"}},"additionalProperties":{}}}}}}}},"401":{"description":"Unauthorized - Authentication is required","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"}},"additionalProperties":{}}}}}}}},"403":{"description":"Forbidden - User does not have permission to access the resource","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"}},"additionalProperties":{}}}}}}}},"404":{"description":"Not Found - The requested resource was not found","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"}},"additionalProperties":{}}}}}}}},"500":{"description":"Internal Server Error. Returned when theres is something wrong with Shield server.","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"}},"additionalProperties":{}}}}}}}},"default":{"description":"An unexpected error response.","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"integer","format":"int32"},"message":{"type":"string"},"details":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"}},"additionalProperties":{}}}}}}}}},"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"userIds":{"type":"array","items":{"type":"string"},"description":"List of user IDs to be added to the organization."}}}}},"required":true},"tags":["Organization"],"method":"post","path":"/v1beta1/organizations/{id}/users","servers":[{"url":"http://127.0.0.1:7400"}],"jsonRequestBodyExample":{"userIds":["string"]},"info":{"title":"Shield Administration API","description":"The Shield APIs adhere to the OpenAPI specification, also known as Swagger, which provides a standardized approach for designing, documenting, and consuming RESTful APIs. With OpenAPI, you gain a clear understanding of the API endpoints, request/response structures, and authentication mechanisms supported by the Shield APIs. By leveraging the OpenAPI specification, developers can easily explore and interact with the Shield APIs using a variety of tools and libraries. The OpenAPI specification enables automatic code generation, interactive API documentation, and seamless integration with API testing frameworks, making it easier than ever to integrate Shield into your existing applications and workflows.","version":"0.2.0","contact":{"name":"Open DataOps Foundation","url":"https://www.odpf.io/","email":"hello@odpf.io"},"license":{"name":"Apache 2.0","url":"https://github.com/odpf/shield/blob/main/LICENSE"}},"postman":{"name":"Add organization user","description":{"content":"Add a user to an organization. A user must exists in Shield before adding it to an org. This request will fail if the user doesn't exists","type":"text/plain"},"url":{"path":["v1beta1","organizations",":id","users"],"host":["{{baseUrl}}"],"query":[],"variable":[{"disabled":false,"description":{"content":"(Required) ","type":"text/plain"},"type":"any","value":"","key":"id"}]},"header":[{"key":"Content-Type","value":"application/json"},{"key":"Accept","value":"application/json"}],"method":"POST","body":{"mode":"raw","raw":"\"\"","options":{"raw":{"language":"json"}}}}}
sidebar_class_name: "post api-method"
info_path: apis/shield-administration-api
custom_edit_url: null
Expand All @@ -26,7 +26,7 @@ import TabItem from "@theme/TabItem";

Add a user to an organization. A user must exists in Shield before adding it to an org. This request will fail if the user doesn't exists

<details style={{"marginBottom":"1rem"}} data-collapsed={false} open={true}><summary style={{}}><strong>Path Parameters</strong></summary><div><ul><ParamsItem className={"paramsItem"} param={{"name":"id","in":"path","required":true,"schema":{"type":"string"}}}></ParamsItem></ul></div></details><MimeTabs><TabItem label={"application/json"} value={"application/json-schema"}><details style={{}} data-collapsed={false} open={true}><summary style={{"textAlign":"left"}}><strong>Request Body</strong><strong style={{"fontSize":"var(--ifm-code-font-size)","color":"var(--openapi-required)"}}> required</strong></summary><div style={{"textAlign":"left","marginLeft":"1rem"}}></div><ul style={{"marginLeft":"1rem"}}><SchemaItem collapsible={false} name={"userIds"} required={false} schemaName={"string[]"} qualifierMessage={undefined} schema={{"type":"array","items":{"type":"string"}}}></SchemaItem></ul></details></TabItem></MimeTabs><div><ApiTabs><TabItem label={"200"} value={"200"}><div>
<details style={{"marginBottom":"1rem"}} data-collapsed={false} open={true}><summary style={{}}><strong>Path Parameters</strong></summary><div><ul><ParamsItem className={"paramsItem"} param={{"name":"id","in":"path","required":true,"schema":{"type":"string"}}}></ParamsItem></ul></div></details><MimeTabs><TabItem label={"application/json"} value={"application/json-schema"}><details style={{}} data-collapsed={false} open={true}><summary style={{"textAlign":"left"}}><strong>Request Body</strong><strong style={{"fontSize":"var(--ifm-code-font-size)","color":"var(--openapi-required)"}}> required</strong></summary><div style={{"textAlign":"left","marginLeft":"1rem"}}></div><ul style={{"marginLeft":"1rem"}}><SchemaItem collapsible={false} name={"userIds"} required={false} schemaName={"string[]"} qualifierMessage={undefined} schema={{"type":"array","items":{"type":"string"},"description":"List of user IDs to be added to the organization."}}></SchemaItem></ul></details></TabItem></MimeTabs><div><ApiTabs><TabItem label={"200"} value={"200"}><div>

A successful response.

Expand Down

0 comments on commit 6c3ac60

Please sign in to comment.