Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Flaresolverr sends numeric values as string #777

Open
3 tasks done
ReadMost opened this issue May 14, 2023 · 1 comment
Open
3 tasks done

Flaresolverr sends numeric values as string #777

ReadMost opened this issue May 14, 2023 · 1 comment
Labels
help wanted Extra attention is needed more information needed Further information is requested

Comments

@ReadMost
Copy link

Have you checked our README?

  • I have checked the README

Is there already an issue for your problem?

  • I have checked older issues, open and closed

Have you checked the discussions?

  • I have read the Discussions

Environment

- FlareSolverr version: v3.1.2
- Last working FlareSolverr version: 
- Operating system: Macos
- Are you using Docker: yes
- FlareSolverr User-Agent (see log traces or / endpoint): yes
- Are you using a VPN: no
- Are you using a Proxy: no
- Are you using Captcha Solver: No
- If using captcha solver, which one:
- URL to test this issue:

Description

How can I change _evil_logic or _post_request to send numeric and boolean values as int and bool data types respectively. Now code sends everything as string thus validation is arisen.
For example: I have been sending payload

{
  "matchingParameters": {
                      "takeCount": 1,
                      ...
                  },
                  "safetyParameters": [
                      {
                          "interestRateBips": 40,
                          ...
                      }
                  ],
}

The response contains validation error as:

{'statusCode': 400, 'message': ['matchingParameters.takeCount must not be greater than 4', 'matchingParameters.takeCount must not be less than 1', 'matchingParameters.takeCount must be an integer number', 'safetyParameters.0.interestRateBips must not be greater than 100000', 'safetyParameters.0.interestRateBips must not be less than 0', 'safetyParameters.0.interestRateBips must be an integer number'], 'error': 'Bad Request'}

the same story for boolean variables. Can someone help or share some idea? I have tried to modify <script>(html) part in _post_request, to be precise i tried to convert string to int and boolean

Logged Error Messages

{'statusCode': 400, 'message': ['matchingParameters.takeCount must not be greater than 4', 'matchingParameters.takeCount must not be less than 1', 'matchingParameters.takeCount must be an integer number', 'safetyParameters.0.interestRateBips must not be greater than 100000', 'safetyParameters.0.interestRateBips must not be less than 0', 'safetyParameters.0.interestRateBips must be an integer number'], 'error': 'Bad Request'}

Screenshots

No response

@ilike2burnthing ilike2burnthing added the help wanted Extra attention is needed label May 15, 2023
@ngosang ngosang added the more information needed Further information is requested label May 21, 2023
@ngosang
Copy link
Member

ngosang commented May 21, 2023

Please post the complete request to FlareSolverr.
If you are trying to POST a JSON it's not supported yet. See:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed more information needed Further information is requested
Projects
None yet
Development

No branches or pull requests

3 participants