Hey @rajivs - This is because we have a safety measure in place which means we ask that api keys are provided via the Secret dataclass.
Long story short, this means you don’t risk having your api key exposed as a bare string when/if you serialize your pipeline to something like YAML.
I tried to add the link to the docs but the platform wont allow me. So go to Haystack docs → Haystack Concepts → Secret Management