My task is to create an LWC component and then add it to a managed package. I was told that to store the API and the key to it, you should use Custom Settings and Custom Metadata Types. No more specifics. Since I'm new, I assumed that the API should be stored in Custom Settings, and the key in Custom Metadata Types.
Next, I try to add a new field and get an error. I understand that this is not how I write the path to my Custom Metadata Types record? Here is my formula:
"the_api_is_specified_here" + $CustomMetadata.Weather_api_key__mdt.key__c
In here is my Custom Metadata Types record (which I am trying to refer to at the end of the formula):
Maybe I'm wrong and I need to implement it in a different way?