0

I need to add a multiple select field (as a component or many to many relation) to the collection type. But I want to fetch data from an external API and show it in the dropdown. can I know how to achieve such kind of implementation?

because strapi won't allow fetching data to a collection type field from external API

niluminda
  • 41
  • 1
  • 6

2 Answers2

1

Strapi as at the time of answering this question does not allow multiple selections for an enumeration field.

The possible way I would recommend is creating the Content-type field as a JSON. Then in your backend controller, you do the checking before validating the data.

0

For Strapi version 4.4.0 and above there is a custom filed plugin that gives you the ability to have a multiple select field. Here is the link --> https://market.strapi.io/plugins/strapi-plugin-multi-select

As for the functionality of fetching data from an external API, here are some ideas that may work.

Hope this helps...

Andreas Oikon
  • 45
  • 1
  • 3
  • 7