NOLookup::Brreg::Entry - Map a Brreg json data structure element to Brreg::Entry data objects.
Map the json data to data objects.
Return a reference to an array of NOLookup::Brreg::Entry objects.
The methods provided by this module.
Set if an error has occured. On errors, the lookup terminates.
Set if a warning has occured. On warnings, the lookup continues.
Further description of an error/warning situation.
If the returned JSON structure contains an unsupported data element, the lookup will be performed, but a warning may be returned and and with a status saying:
'Warning: JSON data key entry not expected: xxxx'
where 'xxxx' is the unexpected key. If this happens, the module should be updated with a new method to support the element 'xxx'.
Map the JSON data structure from Brreg to NOLookup::Brreg::Entry data objects.
Returns a ref. to an array of NOLookup::Brreg::Entry data objects.
If more pages can be fetched, those methods give the URL to that page
Count of total nuber of pages matching the search
Count of results on this page
Count of total results for the search
Data elements are available through acessors in the NOLookup::Brreg::Entry object. This is the possible JSON data methods, which are the accessor methods that can be used to find the returned data elements.
The accessor methods from @json_data_methods
organisasjonsnummer navn oppdateringsid registreringsdatoEnhetsregisteret stiftelsesdato oppstartsdato sisteInnsendteAarsregnskap * organisasjonsform overordnetEnhet maalform registrertIStiftelsesregisteret registrertIFrivillighetsregisteret registrertIMvaregisteret registrertIForetaksregisteret frivilligMvaRegistrertBeskrivelser underAvvikling konkurs underTvangsavviklingEllerTvangsopplosning * forretningsadresse * postadresse * institusjonellSektorkode * naeringskode1 * naeringskode2 * naeringskode3 * _links * page hjemmeside antallAnsatte
Returned values:
Most of the accessor methods returns a single value, like 'navn', which returns a scalar with the name of the organization.
Some of the methods returns a hash, and are marked with an asterix (*). Hash data must be accessed via their respective keys.
The hashes are described below.
The hash looks like follows:
"organisasjonsform": { "kode": "AS", "beskrivelse": "Aksjeselskap", "_links": { "self": { "href": "https://data.brreg.no/enhetsregisteret/api/organisasjonsformer/AS" } } },
"forretningsadresse": { "land": "Norge", "landkode": "NO", "postnummer": "7030", "poststed": "TRONDHEIM", "adresse": [ "Abels gate 5" ], "kommune": "TRONDHEIM", "kommunenummer": "5001" },
'institusjonellSektorkode' => { 'beskrivelse' => 'Statlig eide aksjeselskaper mv.', 'kode' => '1120' }
'naeringskode1' => { 'beskrivelse' => "Utvinning av r\x{e5}olje", 'kode' => '06.100' },
'frivilligMvaRegistrertBeskrivelser' => [ 'Utleier av bygg eller anlegg' ],
"_links": { "self": { "href": "https://data.brreg.no/enhetsregisteret/api/enheter/985821585" } }
For now, support questions should be sent to:
<(nospam)info(at)norid.no>
Please also see the SUPPORT file in the distribution.
NOLookup::Brreg::DataLookup
Trond Haugen, <(nospam)info(at)norid.no>
Copyright (c) 2017- Trond Haugen <(nospam)info(at)norid.no>. All rights reserved.
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.
This library is free software. You can redistribute it and/or modify it under the same terms as Perl itself.
To install NOLookup, copy and paste the appropriate command in to your terminal.
cpanm
cpanm NOLookup
CPAN shell
perl -MCPAN -e shell install NOLookup
For more information on module installation, please visit the detailed CPAN module installation guide.