Skip to main content

Recopilation of backups. API-NPP

Read this in other languages: English, Español, Català.

Keep in mind part of the program is in catalan

Information

  • To execute this program you require python 3 o greater installed. Preferably v3.9

  • Dependencies in requirements.txt

  • Requires a MySQL database with this strucutre: Database structure.

  • 4GB of RAM.

  • 4th gen intel cpu or equivalent AMD.

  • Windows 10, 11, Server 2016 or greater

  • 500 MB of free space without conting database space usage.

  • Stable internet connection.

  • Database config in config/config.yaml

  • Error logs in errorLogs/*txt

  • Use the -h or --help option for more information of Usage

Database structure

Inside the database of your choice it's nedded the table credencials whith the following structure:

The columns names are irrelevant only their positions are.


"name" Primary key, name of the device. Without spaces



"url" Login or API(in case of PandoraFMS) url of the device



"user" User with permission to see the backups



"password" The users password



"cookie/key/apipasswd" To get the cookie open Chrome, or similar, go to the url avobe and inspect element; Once there in the network tabwe do CONTROL+R cliquem al resultat que ens sortira i busquem on esta cookie. The key is the TOTP of the mspbackup. And the apipassword is the password of the Pandora API

If it's not created it will create it automatically.

Installation

  • Using pip:

    pip install Backups_clientAPI-NPP

    or

  • cloning:

    gh repo clone NilPujolPorta/Backups_clientAPI-NPP

Install portable chrome v101 and tesseract in the Backups_clientAPI folder.

Remember to edti the config/config.yaml file to your correct database info.

Usage

Ways of executing the program

  • In the command line Backups-clientAPI-NPP [opcions]

  • python -m Backups-clientAPI [opcions]

  • Execute the file: __main__.py [opcions]

  • ./backups-clientAPI-runner.py [opcions]

  • Importing the package and using in your own project.

  • Creating a task in Windows task manager (Windows task manager is UNABLE to execute the python file directly, use a executable like something.bat file that executes the python file and tell the task manager to execute the .bat file). Use a SIMPLE/BASIC TASK.

Options


usage: __main__.py [-h] [-q] [--portable-chrome-path RUTA] [-tr RUTA] [-g] [--json-file RUTA] [-d SEC] [-v]



An API to recollect backups information from various sources.



optional arguments:

  -h, --help            show this help message and exit

  -q, --quiet           Only shows error messages.

  --portable-chrome-path RUTA

                        Path to portable chrome executable.

  -tr RUTA, --tesseractpath RUTA

                        Route to tesseract.exe

  --json-file RUTA      The path(file not included) where you want to save the json file. 

  -d SEC, --date SEC    The ammount of time (in seconds) back wich the program will look for copies. By default is 2592000(a month)

  -v, --versio          Show the version



For additional configuration options: config/config.yaml

In the near future:

  1. Add suport for other database servers

Release files for Backups-clientAPI-NPP 1.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for Backups-clientAPI-NPP 1.2
File Size Uploaded
Backups_clientAPI-NPP-1.2.tar.gz 26.0 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for Backups-clientAPI-NPP 1.2
File Interpreter ABI Platform
Backups_clientAPI_NPP-1.2-py3-none-any.whl Python 3 none any Details

Total release size: 54.5 kB

Release files / Backups_clientAPI-NPP-1.2.tar.gz

Download URL Backups_clientAPI-NPP-1.2.tar.gz
Size 26.0 kB
Tags Source
SHA-256 checksum
How to use checksums
bdd81bff47aff76b4ada5818764646a23a99834bce05166179d4c5c3f62f0ffa
BLAKE2b-256 checksum
How to use checksums
22d735f0a968a603531b58f4bf4a8ff0d5c56328d95ea0a68d71db995c197fb4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7

Release files / Backups_clientAPI_NPP-1.2-py3-none-any.whl

Download URL Backups_clientAPI_NPP-1.2-py3-none-any.whl
Size 28.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
61d62a74ff9b49b78cb7ff1e598dd1c17521c3c1947d0bca14296578a8ea9baa
BLAKE2b-256 checksum
How to use checksums
ccd42b02f7b992ed290fc52e65a1aa6fe654444862dd30d46ba57708414de3bc
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7

Release history Release notifications | RSS feed

This release

1.2 This release

2 release files

1.1

2 release files

1.0

2 release files

0.1.5

2 release files

0.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page