1

I am wondering what is the way to get edit access to a specific custom metadata using PermissionSet in UI.

Here is what i have done:

  • Setup -> PermissionSet-> MyPSName
  • system permission -> checked View Setup and Configuration
  • custom metadata Types-> added my custom metadata
  • assigned the PS to a user

Logged in with that user:

->setup->custom metadata-> click mycustommetdata->not able to see edit button for the custom metadata

2

There is not currently a way to give a user write access exclusively to custom metadata. Write access is via Customize Application, which, as you've noted in a comment, gives access to a lot of other things as well.

  • Yeah,I am writing a sfdx plugin that generates PS and fetch/evaluates permissions while doing source:pull for any requirement for toggle . i was thinking to add this under idea then thought would ask here if i am really missing something already existing .Thanks Mate – Krishna Kanth Juluru Sep 24 at 14:03
1

As Avrom points out, you can't control edit access using permissions to a specific MDT SObject.

But, if a user has Customize Application privileges and you DON'T want that user to edit an MDT row, you could partially solve this with validation rule(s) on those MDT fields you are trying to protect.

This validation rule would test for the presence of a given custom permission to allow the edit.

  • Would not address deletion of MDT
  • Would not address adding new MDT rows
  • Although a user with Customize Application could also just delete the validation rule. – Avrom Roy-Faderman Oct 14 at 16:56
  • 1
    @AvromRoy-Faderman - yes, suggestion was more about putting in obstacles rather than being bulletproof - sort of like when a guy is being chased in a movie through a kitchen and pushes over a large stack of trays into the way of the pursuer. Delays, not deters an aggressive "user" – cropredy Oct 14 at 17:46
0

The permission set needs to have Author Apex and Customize Application enabled.

This can be found Setup -> Permission Sets -> Click on permission set -> System Permissions -> Edit -> Check Author Apex and Customize Application -> Save

Sauce

  • You should no longer need to use Author Apex, just Customize Application. Is that not working for you? – Avrom Roy-Faderman Sep 20 at 23:28
  • Not OP, didn't test myself only gave the documentation a glance, so honestly couldn't tell you. – Zach Sep 21 at 5:31
  • The Customize application would give me access to multiple other areas of setup (Ex:Auth provider). i was looking if there is a way to get access only to specific custom metadata from UI – Krishna Kanth Juluru Sep 22 at 7:35

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.