Skip to main content

No project description provided

Project description

Dominican Republic Taxpayer Dataset and Search Tool

PyPI - Version PyPI - Python Version PyPI - Status changelog

Simple tool to load the dataset of taxpayers of the Dominican Republic. It can be used to correct data on names or IDs registered in some data source, as well as being integrated into a much larger application.

Source: [https://www.dgii.gov.do/app/WebApps/Consultas/RNC/DGII_RNC.zip]

Installation

pip install dgii-rnc

Dependencies

  • Polars
  • Selenium

How to use

Getting the dataset

from dgii_rnc.dgii_rnc import dgii_handler
import polars as pl

df = dgii_handler.rnc_df()

df.shape
(735018, 7)

df.filter(pl.col("NOMBRE").str.contains("BANCO CENTRAL"))
shape: (4, 7)
+-----------+----------------+----------------+---------------+------------+--------------+--------+
| ID        | NOMBRE         | NOMBRE_COMERCI | CATEGORIA     | FECHA      | REGIMEN_PAGO | ESTADO |
| ---       | ---            | AL             | ---           | ---        | ---          | ---    |
| str       | str            | ---            | str           | str        | str          | str    |
|           |                | str            |               |            |              |        |
+==================================================================================================+
| 401007551 | BANCO CENTRAL  | null           | SERV GRALES   | 23/10/1947 | ACTIVO       | NORMAL |
|           | DE LA          |                | DE LA ADM     |            |              |        |
|           | REPUBLICA      |                | PÚBLICA       |            |              |        |
|           | DOMINICANA     |                |               |            |              |        |
| 430027715 | ARS PLAN SALUD | ARS BANCO      | ADMINISTRACIO | 23/06/2003 | ACTIVO       | NORMAL |
|           | BANCO CENTRAL  | CENTRAL        | N DE RIESGOS  |            |              |        |
|           |                |                | DE S          |            |              |        |
| 401508583 | FONDO DE       | null           | ADMINISTRACIÓ | 24/02/1999 | ACTIVO       | NORMAL |
|           | JUBILACIONES Y |                | N DE FONDOS   |            |              |        |
|           | PENSIONES DEL  |                | DE PE         |            |              |        |
|           | PERSONAL DEL   |                |               |            |              |        |
|           | BANCO CENTRAL  |                |               |            |              |        |
| 430118591 | CLUB EMPLEADOS | CLUB EMPLEADOS | SERV. DE      | 08/09/2011 | ACTIVO       | NORMAL |
|           | DEL BANCO      | DEL BANCO      | ORGANIZACIÓN, |            |              |        |
|           | CENTRAL        | CENTRAL        | DIRECCI       |            |              |        |
+-----------+----------------+----------------+---------------+------------+--------------+--------+

Searches

Local

# 'Csv' search
search_query = dgii_handler.search({'NOMBRE':'BANCO CENTRAL DE LA REPUBLICA'})
print(search_query)
shape: (1, 7)
+-----------+----------------+----------------+---------------+------------+--------------+--------+
| ID        | NOMBRE         | NOMBRE_COMERCI | CATEGORIA     | FECHA      | REGIMEN_PAGO | ESTADO |
| ---       | ---            | AL             | ---           | ---        | ---          | ---    |
| str       | str            | ---            | str           | str        | str          | str    |
|           |                | str            |               |            |              |        |
+==================================================================================================+
| 401007551 | BANCO CENTRAL  | null           | SERV GRALES   | 23/10/1947 | ACTIVO       | NORMAL |
|           | DE LA          |                | DE LA ADM     |            |              |        |
|           | REPUBLICA      |                | PÚBLICA       |            |              |        |
|           | DOMINICANA     |                |               |            |              |        |
+-----------+----------------+----------------+---------------+------------+--------------+--------+

Web

# 'Web' search
web_search_query = dgii_handler.web_search('401007551')
web_search_query.to_dicts()
[{'Cédula/RNC': '401-00755-1',
 'Nombre/Razón Social': 'BANCO CENTRAL DE LA REPUBLICA DOMINICANA',
 'Nombre Comercial': ' ',
 'Categoría': '',
 'Régimen de pagos': 'NORMAL',
 'Estado': 'ACTIVO',
 'Actividad Economica': 'SERV GRALES DE LA ADM PÚBLICA (INCL. EL DESEMPEÑO DE FUNCIONES EJECUTIVAS Y LEGISLATIVAS DE ADM POR PARTE DE LAS ENTIDADES DE LA A',
 'Administracion Local': 'ADM LOCAL GGC'}]

Convert to pandas dataframe

df = df.to_pandas()

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

dgii_rnc-0.6.tar.gz (5.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

dgii_rnc-0.6-py3-none-any.whl (5.4 kB view details)

Uploaded Python 3

File details

Details for the file dgii_rnc-0.6.tar.gz.

File metadata

  • Download URL: dgii_rnc-0.6.tar.gz
  • Upload date:
  • Size: 5.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.12.4

File hashes

Hashes for dgii_rnc-0.6.tar.gz
Algorithm Hash digest
SHA256 43b2cbc5c858f120912bdd7ce55fe90c35950379195229da8795913481531026
MD5 8e703a289cca39a5c404ed8e607aa78e
BLAKE2b-256 4dd991382cb1a1d91c073f3e58c37ff8f27804acb0bf0ae33201fa3f78066b21

See more details on using hashes here.

File details

Details for the file dgii_rnc-0.6-py3-none-any.whl.

File metadata

  • Download URL: dgii_rnc-0.6-py3-none-any.whl
  • Upload date:
  • Size: 5.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.12.4

File hashes

Hashes for dgii_rnc-0.6-py3-none-any.whl
Algorithm Hash digest
SHA256 1c8f2cb927f074ee5ff0c799111f28e74769f2150b3c254a51638e9213ca991e
MD5 a526db440760011c354c359c26a267fe
BLAKE2b-256 5678305992294f70e3144406887e50d3ec0f93f0822d46b9e3338065a4c5d3a3

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page