HAALCENTRAAL English translation
BRP API / Personen / Features / fout-cases-gba

Search by house number designation identification - error cases

#language: en

@gba
Feature: Search by house number designation identification - error cases

Rule: nummeraanduidingIdentificatie is a mandatory parameter

  @fout-case
  Scenario: The nummeraanduidingIdentificatie parameter has not been supplied
    When gba persons are searched with the following parameters
    | naam   | waarde                               |
    | type   | ZoekMetNummeraanduidingIdentificatie |
    | fields | burgerservicenummer                  |
    Then the response has an object with the following data
    | naam     | waarde                                                        |
    | type     | https://datatracker.ietf.org/doc/html/rfc7231#section-6.5.1   |
    | title    | Een of meerdere parameters zijn niet correct.                 |
    | status   | 400                                                           |
    | detail   | De foutieve parameter(s) zijn: nummeraanduidingIdentificatie. |
    | code     | paramsValidation                                              |
    | instance | /haalcentraal/api/brp/personen                                |
    And the object has the following 'invalidParams' data
    | code     | name                          | reason                  |
    | required | nummeraanduidingIdentificatie | Parameter is verplicht. |

  @fout-case
  Scenario: An empty string has been supplied as the house number designation identification value
    When gba persons are searched with the following parameters
    | naam                          | waarde                               |
    | type                          | ZoekMetNummeraanduidingIdentificatie |
    | nummeraanduidingIdentificatie |                                      |
    | fields                        | burgerservicenummer                  |
    Then the response has an object with the following data
    | naam     | waarde                                                        |
    | type     | https://datatracker.ietf.org/doc/html/rfc7231#section-6.5.1   |
    | title    | Een of meerdere parameters zijn niet correct.                 |
    | status   | 400                                                           |
    | detail   | De foutieve parameter(s) zijn: nummeraanduidingIdentificatie. |
    | code     | paramsValidation                                              |
    | instance | /haalcentraal/api/brp/personen                                |
    And the object has the following 'invalidParams' data
    | code     | name                          | reason                  |
    | required | nummeraanduidingIdentificatie | Parameter is verplicht. |

Rule: A nummeraanduidingIdentificatie is a string of exactly 16 digits

  @fout-case
  Scenario Outline: <titel>
    When gba persons are searched with the following parameters
    | naam                          | waarde                               |
    | type                          | ZoekMetNummeraanduidingIdentificatie |
    | nummeraanduidingIdentificatie | <nummeraanduidingIdentificatie>      |
    | fields                        | burgerservicenummer                  |
    Then the response has an object with the following data
    | naam     | waarde                                                        |
    | type     | https://datatracker.ietf.org/doc/html/rfc7231#section-6.5.1   |
    | title    | Een of meerdere parameters zijn niet correct.                 |
    | status   | 400                                                           |
    | detail   | De foutieve parameter(s) zijn: nummeraanduidingIdentificatie. |
    | code     | paramsValidation                                              |
    | instance | /haalcentraal/api/brp/personen                                |
    And the object has the following 'invalidParams' data
    | code    | name                          | reason                                       |
    | pattern | nummeraanduidingIdentificatie | Waarde voldoet niet aan patroon ^[0-9]{16}$. |

    Examples:
    | nummeraanduidingIdentificatie     | titel                                                                              |
    | 123456789012345                   | De opgegeven nummeraanduidingIdentificatie is een string met minder dan 16 cijfers |
    | 12345678901234567                 | De opgegeven nummeraanduidingIdentificatie is een string met meer dan 16 cijfers   |
    | <script>1234567890123456</script> | De opgegeven nummeraanduidingIdentificatie bevat niet-cijfer karakters             |

Rule: inclusiefOverledenPersonen is a boolean (a true or false value)

  @fout-case
  Scenario Outline: An invalid value has been supplied for the 'inclusiefOverledenPersonen' parameter
    When gba persons are searched with the following parameters
    | naam                          | waarde                               |
    | type                          | ZoekMetNummeraanduidingIdentificatie |
    | nummeraanduidingIdentificatie | 0599200051001501                     |
    | fields                        | burgerservicenummer                  |
    | inclusiefOverledenPersonen    | <inclusief overleden personen>       |
    Then the response has an object with the following data
    | naam     | waarde                                                      |
    | type     | https://datatracker.ietf.org/doc/html/rfc7231#section-6.5.1 |
    | title    | Een of meerdere parameters zijn niet correct.               |
    | status   | 400                                                         |
    | detail   | De foutieve parameter(s) zijn: inclusiefOverledenPersonen.  |
    | code     | paramsValidation                                            |
    | instance | /haalcentraal/api/brp/personen                              |
    And the object has the following 'invalidParams' data
    | code    | name                       | reason                  |
    | boolean | inclusiefOverledenPersonen | Waarde is geen boolean. |

    Examples:
    | inclusief overleden personen |
    |                              |
    | geen boolean                 |

Rule: Only the parameters specified for the search type supplied may be used

  @fout-case
  Scenario Outline: <titel>
    When gba persons are searched with the following parameters
    | naam                          | waarde                               |
    | type                          | ZoekMetNummeraanduidingIdentificatie |
    | nummeraanduidingIdentificatie | 0599200051001501                     |
    | <parameter>                   | <waarde>                             |
    | fields                        | burgerservicenummer                  |
    Then the response has an object with the following data
    | naam     | waarde                                                      |
    | type     | https://datatracker.ietf.org/doc/html/rfc7231#section-6.5.1 |
    | title    | Een of meerdere parameters zijn niet correct.               |
    | status   | 400                                                         |
    | detail   | De foutieve parameter(s) zijn: <parameter>.                 |
    | code     | paramsValidation                                            |
    | instance | /haalcentraal/api/brp/personen                              |
    And the object has the following 'invalidParams' data
    | code         | name        | reason                      |
    | unknownParam | <parameter> | Parameter is niet verwacht. |

    Examples:
    | titel                                     | parameter              | waarde     |
    | zoeken met parameter uit ander zoektype   | voornamen              | Pietje     |
    | typfout in naam optionele parameter       | gemeenteVanInschijving | 0363       |
    | zoeken met niet gespecificeerde parameter | bestaatNiet            | een waarde |