semvec/pypi-packages huggingface dataset:
theoneapi 0.0.1
This SDK provides (partial) access to LibLab's Lord of the Rings API - The One API to rule them all.
License: MIT
Requires Python: >=3.9
Keywords: liblab,sdk,api

# raffy_kaloustian-SDK

This SDK provides (partial) access to [LibLab](https://liblab.com/)'s Lord of the Rings API - [The One API to rule them all](https://the-one-api.dev).

## Supported Python Version

This SDK supports Python 3.9 or higher.

## Installation

Install using pip from PyPi.

```shell
pip3 install theoneapi
```

## Example Usage

See examples.py.

```python
from theoneapi.client import Client
from theoneapi.query import Query

# sign up to get an access token: https://the-one-api.dev
client = Client('ACCESS_TOKEN')


'''
Movie Examples
'''

# get one movie (by id)
movie = client.movie.get_one('5cd95395de30eff6ebccde56')

# get all movies
movies = client.movie.get_all()

# get all movie quotes (by movie id)
# (see below for another way to get this as well)
movie_quotes_1 = client.movie.get_all_quotes('5cd95395de30eff6ebccde5b')


''' 
Quote Examples
'''

# get one quote (by id)
quote = client.quote.get_one('5cd96e05de30eff6ebcce92e')

# get all quotes
quotes = client.quote.get_all()

# get all movie quotes (by movie id)
# (see above for another way to get this as well)
movie_quotes_2 = client.quote.get_all_from_movie('5cd95395de30eff6ebccde5b')


'''
Query Option Examples
'''

query = Query()

# get paginated quotes
quotes_paginated = client.quote.get_all(
    query.paginate(offset=2, limit=3, page=1)
)

# get movies sorted ascending
movies_sorted = client.movie.get_all(
    query.sort_asc('name')
)

# get movies sorted ascending
movie_matched_name = client.movie.get_all(
    query.filter_match('name', 'The Two Towers')
)

# chaining query options
quotes_chained_query = client.quote.get_all(
    query.filter_match('movie', '5cd95395de30eff6ebccde5b').paginate(limit=5)
)
```

## Query Options

```python
from theoneapi.query import Query


query = Query()

# pagination
query.paginate(limit=limit, page=page, offset=offset)

# sorting
query.sort_asc(field)
query.sort_desc(field)

# filtering
query.filter_match(field, value)
query.filter_not_match(field, value)
query.filter_include(field, value)
query.filter_exclude(field, value)
query.filter_exists(field)
query.filter_not_exists(field)
query.filter_regex(field, value)
query.filter_not_regex(field, value)
query.filter_less_than(a, b)
query.filter_lt(a, b) # same as query.filter_less_than(a, b)
query.filter_greater_than(a, b)
query.filter_gt(a, b) # same as query.filter_greater_than(a, b)
query.filter_greater_than_equal_to(a, b)
query.filter_gte(a, b) # same as query.filter_greater_than_equal_to(a, b)
```
swedish-market-insights 0.3.0
Package to scrape the Finansinspektion's registers
License: MIT
Requires Python: >=3.9,<4.0

# Swedish Market Insights

SMI is a small package for fetching inside trades made in Sweden.
The data is collected with `requests` and parsed with `BeautifulSoup4`
and returned as a `pandas.DataFrame`.

All data is publicly available on Finansinspektionen's [website](https://fi.se/).

## Installation

```
pip install swedish-market-insights
```

## Usage

```python3
from swedish_market_insights.inside_trades import InsideTradesAPI
from swedish_market_insights.short_positions import ShortPositionsAPI

recent_inside_trades = InsideTradesAPI.get_trades_by_transaction_date()
current_short_positions = ShortPositionsAPI.get_current_short_positions()
```

## Features

### Inside Trades
- Fetch inside trades by transaction date
- Fetch inside trades by publication date

### Short Positions
- Fetch current short positions
- Fetch historical short positions
- Fetch aggregated short positions

## Examples

### Fetch inside trades by transaction date

```python3
from swedish_market_insights.inside_trades import InsideTradesAPI
from datetime import date

trades = InsideTradesAPI.get_trades_by_transaction_date(
    from_date=date(2020, 1, 1),
    to_date=date(2020, 1, 31))
```

### Fetch inside trades by publication date

```python3
from swedish_market_insights.inside_trades import InsideTradesAPI
from datetime import date

trades = InsideTradesAPI.get_trades_by_publish_date(
    from_date=date(2022, 10, 8),
    to_date=date(2022, 10, 10))
```

### Fetch current short positions

```python3
from swedish_market_insights.short_positions import ShortPositionsAPI

current_short_positions = ShortPositionsAPI.get_current_short_positions()
```

## Contributing

Contributions are welcome! Please open an issue or submit a pull request on GitHub if you have any suggestions or
improvements.

## License

This project is licensed under the MIT License.