Can anyone point to the docs that discuss private ...
# suitecommerce
c
Can anyone point to the docs that discuss private fields in JSON config files? I can't find them anywhere.
s
Private fields in JSON config files?
c
If you create a key
private.somekey
in a JSON config file, the private field doesn't show up in the front end and is still available to SuiteScript code on the back end.
s
That doesn’t sound like a SuiteCommerce feature I know of
Can you point to a file in the SCA bundle where we’ve done that?
c
I'll check.
This appears to be a third party mod.
Sorry!
s
Now I’m really curious 😅
c
It would be useful as a feature for sure.
s
Example use case?
c
Override Configuration.get() to throw out all
private
keys before it returns. Then you can have keys for font end and back end in the Configuration UI.
I'm assuming this is done in checkout.ssp or shopping.ssp
checkoutEnvironment.CONFIGURATION = Configuration.get();
s
I meant more what are you using it for? Storing API secrets?
c
Yes, API keys and such,
1000000 1