Skip to content

Document allowedContributers better #2071

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
bjorntore opened this issue Mar 17, 2025 · 0 comments
Open

Document allowedContributers better #2071

bjorntore opened this issue Mar 17, 2025 · 0 comments

Comments

@bjorntore
Copy link
Contributor

bjorntore commented Mar 17, 2025

Description

It's hard to understand what allowedContributers can be used for. Document further, for instance here: https://docs.altinn.studio//nb/api/models/app-metadata/#datatype

Draft from which inspiration can be taken: #2072

Det er en ekstra autorisasjonsmekanisme for å gjøre det slik at kun tjenesteeier- og sluttbrukertokens kan redigere dataelementer av datatypen.

Man kan feks. sette inn "orgno:123456789", og da vil kun tokens som inneholder det org.nr kunne redigere.

For datatyper som hverken TE eller sluttbruker skal kunne redigere setter man "app:owned". Kun appen sin interne kode kan da redigere dataene.

På lokalt utvikligsmiljø vil man få en exception som minner om å sette dette på signatur- og betalingsdatatyper.

Additional Information

Here is the raw code for the functionality:
https://github.com/Altinn/app-lib-dotnet/blob/a79c86d6d72e41b9d54122d419564cdbafd9c42a/src/Altinn.App.Api/Helpers/DataElementAccessChecker.cs#L16

This is called from the data controller to check if the user can edit data elements of the data type.

Tasks

No response

Acceptance Criterias

No response

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: 📈 Todo
Development

No branches or pull requests

1 participant