How to let a user select a "short name" for a longer piece of content to inject into an API?

Hi there,

First to quickly outline the use case and problem:

Step 1. The user writes some content and also give a reference name to it, eg. :

Issue 1 :
Reference Name - Bananas
Content - Bananas have been poor quality lately. This is due to…

Issue 2 :
Reference Name - Apples
Content - Apples have been great quality lately. This is due to…

etc.

They save both the reference name and the content.

Step 2. They then on a separate page where the content is generated, they have a multi select dropdown menu where they can pick which issues they want to talk about by their reference name.

Eg. They select Bananas.

Step 3. The Content of Bananas is injected into a prompt and they receive a result.

Here’s where I don’t know how to proceed after scratching my head for more time than I care to admit; how do I get the content to be injected into the prompt rather than the reference name?

Thank you in advance,

Hey,

It depend on your DB structure.

I imagine that the Reference Name and Content are saved as two fields of one thing.
If it’s the case, you can, everywhere in your app, call the content field by doing a search with the Reference Name.

You have a DataType “Issues”, with fields “reference”, “content”, and “created by”.
When you want to retrieve the content with only the reference name, you make a “do a search for”

Type:
“issues”,

constraint:
“created by”: This user
“reference”: dropdown value

then :first Item:content value.

You have now your content text, and can send it where you want.

Hope it’s clear !

1 Like

This topic was automatically closed after 69 days. New replies are no longer allowed.