diff --git a/bbb-graphql-server/metadata/databases/BigBlueButton/tables/public_v_user_metadata.yaml b/bbb-graphql-server/metadata/databases/BigBlueButton/tables/public_v_user_metadata.yaml index 7e63486977..b0457fdcd9 100644 --- a/bbb-graphql-server/metadata/databases/BigBlueButton/tables/public_v_user_metadata.yaml +++ b/bbb-graphql-server/metadata/databases/BigBlueButton/tables/public_v_user_metadata.yaml @@ -18,3 +18,15 @@ select_permissions: _eq: X-Hasura-MeetingId - userId: _eq: X-Hasura-UserId + - role: bbb_client_not_in_meeting + permission: + columns: + - parameter + - value + filter: + _and: + - meetingId: + _eq: X-Hasura-MeetingId + - userId: + _eq: X-Hasura-UserId + comment: "" diff --git a/bbb-graphql-server/metadata/query_collections.yaml b/bbb-graphql-server/metadata/query_collections.yaml index ae5fd34da1..b251e09352 100644 --- a/bbb-graphql-server/metadata/query_collections.yaml +++ b/bbb-graphql-server/metadata/query_collections.yaml @@ -8,3 +8,11 @@ clientSettingsJson } } + - name: userMetadata + query: | + query getUserMetadata { + user_metadata { + parameter + value + } + } diff --git a/bbb-graphql-server/metadata/rest_endpoints.yaml b/bbb-graphql-server/metadata/rest_endpoints.yaml index 77cceee094..46a1e8edb3 100644 --- a/bbb-graphql-server/metadata/rest_endpoints.yaml +++ b/bbb-graphql-server/metadata/rest_endpoints.yaml @@ -7,3 +7,12 @@ - GET name: clientSettings url: clientSettings +- comment: "" + definition: + query: + collection_name: allowed-queries + query_name: userMetadata + methods: + - GET + name: userMetadata + url: userMetadata diff --git a/build/packages-template/bbb-graphql-middleware/graphql.nginx b/build/packages-template/bbb-graphql-middleware/graphql.nginx index 620cd81801..e1049ef8da 100644 --- a/build/packages-template/bbb-graphql-middleware/graphql.nginx +++ b/build/packages-template/bbb-graphql-middleware/graphql.nginx @@ -26,3 +26,14 @@ location /api/rest/clientSettings { proxy_set_header Host $host; proxy_pass http://127.0.0.1:8085; #Hasura } + +location /api/rest/userMetadata { + auth_request /bigbluebutton/connection/checkGraphqlAuthorization; + auth_request_set $meeting_id $sent_http_meeting_id; + + proxy_http_version 1.1; + proxy_set_header Upgrade $http_upgrade; + proxy_set_header Connection "Upgrade"; + proxy_set_header Host $host; + proxy_pass http://127.0.0.1:8085; #Hasura +}