api_entreprise: add a feature flag for toggling API INSEE v3
This commit is contained in:
parent
b74fdd3cc8
commit
6c8280fba6
2 changed files with 7 additions and 1 deletions
|
@ -42,7 +42,11 @@ class ApiEntreprise::API
|
|||
def self.url(resource_name, siret_or_siren)
|
||||
base_url = [API_ENTREPRISE_URL, resource_name, siret_or_siren].join("/")
|
||||
|
||||
"#{base_url}?with_insee_v3=true"
|
||||
if Flipflop.insee_api_v3?
|
||||
base_url += "?with_insee_v3=true"
|
||||
end
|
||||
|
||||
base_url
|
||||
end
|
||||
|
||||
def self.params(siret_or_siren, procedure_id)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue