Skip to main content
# AWS-360-API

A Python Flask API used in AWS-360

## Install

```shell
pip install aws-360-api
```

## Endpoints

### `/heartbeat`

Returns with `200` if the application is healthy

* Example:

```json
{
"msg": "I am an healthy flask app",
"status": "success",
"time": "2018-09-24 22:17:38.212565"
}
```

### `/info`

Returns with `200` with application information

* Example:

```json
{
"git_revision": null,
"git_tag": null,
"server_name": "flask-api-alb-public-1654579006.us-east-1.elb.amazonaws.com"
}
```

### `/badge`

Returns a badge (![badge](https://img.shields.io/badge/style-plastic-green.svg?longCache=true&style=plastic))

* Params:
* `name`: Name of the badge
* `percent`: Percentage on the right hand side
* `type`: [`json` or `html`]

```json
$ <api-endpoint>/badge?name=ccm&percent=95&type=json
```

![badge](https://img.shields.io/badge/style-plastic-green.svg?longCache=true&style=plastic)

```json
$ <api-endpoint>/badge?name=ccm&percent=95&type=json
{
"svg": "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<svg xmlns=\"http://www.w3.org/2000/svg\" width=\"77\" height=\"20\">\n <linearGradient id=\"b\" x2=\"0\" y2=\"100%\">\n <stop offset=\"0\" stop-color=\"#bbb\" stop-opacity=\".1\"/>\n <stop offset=\"1\" stop-opacity=\".1\"/>\n </linearGradient>\n <mask id=\"a\">\n <rect width=\"77\" height=\"20\" rx=\"3\" fill=\"#fff\"/>\n </mask>\n <g mask=\"url(#a)\">\n <path fill=\"#555\" d=\"M0 0h31v20H0z\"/>\n <path fill=\"#4c1\" d=\"M31 0h46v20H31z\"/>\n <path fill=\"url(#b)\" d=\"M0 0h77v20H0z\"/>\n </g>\n <g fill=\"#fff\" text-anchor=\"middle\" font-family=\"DejaVu Sans,Verdana,Geneva,sans-serif\" font-size=\"11\">\n <text x=\"16.5\" y=\"15\" fill=\"#010101\" fill-opacity=\".3\">ccm</text>\n <text x=\"15.5\" y=\"14\">ccm</text>\n </g>\n <g fill=\"#fff\" text-anchor=\"middle\" font-family=\"DejaVu Sans,Verdana,Geneva,sans-serif\" font-size=\"11\">\n <text x=\"55.0\" y=\"15\" fill=\"#010101\" fill-opacity=\".3\">95.0</text>\n <text x=\"54.0\" y=\"14\">95.0</text>\n </g>\n</svg>"
}
```

### `/scrappe`

Parses an HTML body and extract `img` HTML tags from a url

* Params:
* `url`: Valid URL to a website

```json
$ <api-endpoint>/scrappe?url=https://github.com

{
"hit": 34,
"imgs": [
{
"src": "https://assets-cdn.github.com/images/search-shortcut-hint.svg"
},
{
"src": "https://assets-cdn.github.com/images/spinners/octocat-spinner-128.gif"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/building-the-future/green-purple-hexagons.png"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/logos/airbnb-logo.png"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/logos/sap-logo.png"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/logos/ibm-logo.png"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/logos/google-logo.png"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/logos/paypal-logo.png"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/logos/bloomberg-logo.png"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/logos/spotify-logo.png"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/logos/swift-logo.png"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/logos/facebook-logo.png"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/logos/node-logo.png"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/logos/nasa-logo.png"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/logos/walmart-logo.png"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/home-illo-team.svg"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/home-illo-team-code.svg"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/home-illo-team-chaos.svg"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/home-illo-team-tools.svg"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/home-illo-business.png"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/integrators/slackhq.png"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/integrators/zenhubio.png"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/integrators/travis-ci.png"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/integrators/atom.png"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/integrators/circleci.png"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/integrators/google.png"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/integrators/codeclimate.png"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/stories/developers/ariya.png"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/stories/developers/freakboy3742.png"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/stories/customers/mailchimp.png"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/stories/developers/kris-nova.png"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/stories/developers/yyx990803.png"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/stories/customers/mapbox.png"
},
{
"src": "https://assets-cdn.github.com/images/modules/site/stories/developers/jessfraz.png"
}
],
"status": "success"
}
```


Made with ♥ for teaching people

Metadata

Release files for aws360api 0.0.12

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

Source distribution (sdist)

Source distribution for aws360api 0.0.12
File Size Uploaded
aws360api-0.0.12.tar.gz 8.8 kB Details

Release files / aws360api-0.0.12.tar.gz

Download URL aws360api-0.0.12.tar.gz
Size 8.8 kB
Tags Source
SHA-256 checksum
How to use checksums
3562f284c0bacb15551c557995e62296ce9f96026eb8c825b3692fb031825f55
BLAKE2b-256 checksum
How to use checksums
2504f124b97ec39e7b859e4ff2b1df42a288735859a28b8771383972074211fc
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.12.1 pkginfo/1.5.0.1 requests/2.19.1 setuptools/40.7.0 requests-toolbelt/0.8.0 tqdm/4.30.0 CPython/2.7.15

Release history Release notifications | RSS feed

This release

0.0.12 This release

1 release file

0.0.11

1 release file

0.0.10

1 release file

0.0.9

1 release file

0.0.8

1 release file

0.0.7

1 release file

0.0.6

1 release file

0.0.5

1 release file

0.0.4

1 release file

0.0.3

1 release file

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