The value has to be of type 'noValidate', you provided a value of type 'string'" error

Can anyone explain why it is saying "The value has to be of type 'noValidate', you provided a value of type 'string'" when I am inputting a value for a query parameter? The parameter requires a string and the code passing the value evaluates to a string, but it still gives me that error. Why would it have a problem if I am passing in a string when that is what the parameter requires?

Hey @dfresh527,

I've encountered the same issue before with the default Slack REST API conversations.history endpoint β€” it may be a bug. However, I found a better solution that worked well for me.

Instead of relying on the default behavior, you can create a custom REST API using an authorization token. This approach has proven to be more reliable and works perfectly.

Let me know if you need help setting it up!

5 Likes

Hi @WidleStudioLLP thanks for the reply!

If it's a bug, that's pretty annoying... but I went ahead and tried your approach.

I'm pretty sure I have everything setup correctly, but I keep getting a "request to https://slack/com/api/conversations.history/?channel=CNEUWQ2FL failed, reason: getaddrinfo ENOTFOUND slack" error message. Below are screenshots showing the configuration. I put the auth bearer token in the resource header parameter instead of the query, but I think it should work the same.

Any idea why it's not working?? Thanks for your help!

@dfresh527,
I can try to help you debug this. One thing I'm noticing is your scopes. Scopes should not be separated with commas, but with spaces. (not even an end of line break, but just single space). See if that resolves your issue.

Hey @lindakwoo yeah I did that (separating scopes with spaces) initially, but tried changing it because that's what Slack's API docs specify. Neither way worked though :frowning:

Hey @dfresh527,

I understand you're encountering an error, and I can help guide you through the complete process to create a Slack app and retrieve conversation history. Here's a step-by-step overview:


1. Create a Slack App

Start by creating a new app in the Slack API Dashboard under your desired workspace.


2. Configure OAuth & Permissions

  • Go to the app settings.
  • Navigate to OAuth & Permissions.
  • Add your Redirect URL as shown below:


3. Add Required Scopes

Under OAuth & Permissions, add the following scopes needed to access conversation history:


4. Install the App in Your Workspace

Once the app is configured, install it in your workspace. Be sure to also:

  • Add the app to the Slack channel where you want to retrieve messages.
  • This can be done from the Slack channel integration settings:


5. API Access – No Need for Client ID or Secret

When making API calls to retrieve conversation history, you do not need to include your Client ID or Secretβ€”only your access token is required.

Here’s a screenshot of how my API call is set up:

3 Likes

@dfresh527,
I think your url may be incorrect? I think you have slack/com instead of slack.com.

2 Likes

@dfresh527,
Just checking in to see if your issue is resolved.

Hi Lindakwoo how are you?
I'm experiencing similar issue since yesterday, for example if i need to send a slack message with the username 'workflow - Support Debt' it used to work passing the string, now it says it should be novalidate, is there a way to cast it or how can this bug be fixed?

Thanks!

The message output ends up with the User Retool with the Retool logo

@Ignacio_Gar,
I have been unable to reproduce the issue with the 'noValidate' error with the Retool Slack resource, but the workaround is to create a Rest api and use the slack api. Meanwhile I will try to see if I can reproduce.

@dfresh527 and @Ignacio_Gar,
When my cursor is still inside the text field I do get this error:


But as soon as I click outside of it, it goes away and my query runs fine. Do you get the same behavior?

Yes! It's the same behavior
And if you excecute it the name on the message should not be 'lindakwoo' on slack

@Ignacio_Gar,
Hmmm, no, my user on slack is lindakwoo.

Yours is not recognizing the string. Are you on Retool Cloud?

@Ignacio_Gar,
Can you provide me with the full screenshot of the results from your workflow run? I want to see what is in the "message" object and what your "username" is in there.

Hi, yes sorry! Got it all taken care of, thank you! And you were right, it was simply a problem with my embarrassingly poor attention to detail :flushed:

@dfresh527,
It happens to all of us! Meanwhile I will still try to get to the bottom of why the built in Retool slack resource gives that error with strings and file a bug request if necessary.

@Ignacio_Gar,
I am fairly sure this is a linting error and the request will work. Please let me know if you think otherwise. Otherwise I will close out this thread.