Metadata-Version: 2.1
Name: MicrosoftDesigner
Version: 0.0.6
Summary: High quality image generation by Microsoft Designer. Reverse engineered API.
Home-page: https://github.com/imnotdev25/Msdesigner-api
Author: Talaviya Bhavik
Author-email: talaviyabhavik@proton.me
License: GNU General Public License v2.0
Project-URL: Bug Report, https://github.com/imnotdev25/Msdesigner-api/issues/new
Classifier: License :: OSI Approved :: GNU General Public License v2 (GPLv2)
Classifier: Intended Audience :: Developers
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: httpx

# Microsoft Designer API

### Installation

```$ pip3 install MicrosoftDesigner```

### Usage

``` 
$ python3 -m MicrosoftDesigner -h

options:
  -h, --help            show this help message and exit
  --user_id USER_ID     User ID
  --auth_token AUTH_TOKEN
                        Auth Token
  --prompt PROMPT       Prompt
  --save_path FILE_PATH
                        File Path to save the output (optional)
  --file_name FILE_NAME
                        File Name to save the output (optional)

```
## Getting Started
- Create a new user account or login [Microsoft Designer](https://designer.microsoft.com/)
- Open the developer tools and go to the network tab
- Create a new image using random text
- Find the request with post method and copy the request headers
- Copy the user id, auth token (Authorization: value) from the request headers
- Run the script with the copied values
- Note: **auth_token will expire after 24 hours**

```
$ python3 -m MicrosoftDesigner --user_id <user_id> --auth_token <auth_token> --prompt <prompt>

```
### **Python Example**


```

from Msdesigner.create_images import create_image
create_image(user_id, auth_token, prompt)

# Image wiil be saved in images folder
# Async function

from Msdesigner.create_images import async_create_image
async_create_image(user_id, auth_token, prompt)

```

