Project

General

Profile

Actions

Feature #3026

open

Enable apipie API parameter validation

Added by Dominic Cleal over 10 years ago. Updated about 6 years ago.

Status:
New
Priority:
Normal
Assignee:
-
Category:
API
Target version:
-
Difficulty:
Triaged:
Fixed in Releases:
Found in Releases:

Description

Currently we have apipie's built in parameter validation disabled in config/initializers/apipie.rb:

Apipie.configure do |config|
  config.validate = false
end

I think - if our documentation is accurate - then this might be useful.


Related issues 1 (1 open0 closed)

Related to Foreman - Feature #22285: Present error message when passing integer when array expected for API callNewTomer BriskerActions
Actions #1

Updated by Dominic Cleal over 10 years ago

It turns out there's some history to this:

https://github.com/theforeman/foreman/commit/5d78633efd6fb9751da1e2776313c0faf22e3978

It makes sense to rely on AR when we're working directly with AR objects and updating their attributes, but the instance I'm looking at is in the report import action, which uses the parameters more directly, so we miss the validation.

Actions #2

Updated by Marek Hulán about 6 years ago

  • Bugzilla link set to 1557053
Actions #3

Updated by Marek Hulán about 6 years ago

  • Related to Feature #22285: Present error message when passing integer when array expected for API call added
Actions

Also available in: Atom PDF