diff --git a/independent-publisher-connectors/Monster API/apiDefinition.swagger.json b/independent-publisher-connectors/Monster API/apiDefinition.swagger.json new file mode 100644 index 000000000..b9c46c038 --- /dev/null +++ b/independent-publisher-connectors/Monster API/apiDefinition.swagger.json @@ -0,0 +1,765 @@ +{ + "swagger": "2.0", + "info": { + "title": "Monster API", + "description": "With Monster API, you can effortlessly access powerful generative AI models such as Stable Diffusion for text to image and image to image.", + "version": "1.0", + "contact": { + "name": "Troy Taylor", + "url": "https://www.hitachisolutions.com", + "email": "ttaylor@hitachisolutions.com" + } + }, + "host": "api.monsterapi.ai", + "basePath": "/apis/", + "schemes": [ + "https" + ], + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "paths": { + "/add-text-task": { + "post": { + "responses": { + "200": { + "description": "default", + "schema": { + "type": "object", + "properties": { + "message": { + "type": "string", + "description": "The task message.", + "title": "Message" + }, + "process_id": { + "type": "string", + "description": "The process identifier.", + "title": "Process ID" + } + } + } + } + }, + "summary": "Get image from text", + "operationId": "TextImageAddPost", + "description": "Generates an image that looks similar to your provided text prompt using the Stable Diffusion model.", + "parameters": [ + { + "name": "body", + "in": "body", + "required": false, + "schema": { + "type": "object", + "properties": { + "model": { + "type": "string", + "description": "The model.", + "title": "Model", + "default": "txt2img", + "x-ms-visibility": "internal" + }, + "data": { + "type": "object", + "properties": { + "prompt": { + "type": "string", + "description": "The prompt.", + "title": "Prompt" + }, + "negprompt": { + "type": "string", + "description": "The negative prompt.", + "title": "Neg Prompt" + }, + "samples": { + "type": "integer", + "format": "int32", + "description": "The samples.", + "title": "Samples" + }, + "steps": { + "type": "integer", + "format": "int32", + "description": "The steps.", + "title": "Steps" + }, + "aspect_ratio": { + "type": "string", + "description": "The aspect ratio.", + "title": "Aspect Ratio" + }, + "guidance_scale": { + "type": "number", + "format": "float", + "description": "The guidance scale.", + "title": "Guidance Scale" + }, + "seed": { + "type": "integer", + "format": "int32", + "description": "The seed.", + "title": "Seed" + } + }, + "title": "Data", + "required": [ + "prompt" + ] + } + }, + "required": [ + "model", + "data" + ] + } + } + ], + "x-ms-visibility": "important" + } + }, + "/task-text-status": { + "post": { + "responses": { + "200": { + "description": "default", + "schema": { + "type": "object", + "properties": { + "message": { + "type": "string", + "description": "The task message.", + "title": "Message" + }, + "response_data": { + "type": "object", + "properties": { + "process_id": { + "type": "string", + "description": "The process identifier.", + "title": "Process ID" + }, + "status": { + "type": "string", + "description": "The status.", + "title": "Status" + }, + "result": { + "type": "object", + "properties": { + "output": { + "type": "array", + "items": { + "type": "string" + }, + "description": "The outputs.", + "title": "Outputs" + } + }, + "title": "Result" + }, + "credit_used": { + "type": "integer", + "format": "int32", + "description": "The amount of credit used.", + "title": "Credit Used" + }, + "overage": { + "type": "integer", + "format": "int32", + "description": "The overage.", + "title": "Overage" + } + }, + "title": "Response Data" + } + } + } + } + }, + "summary": "Get image from text status", + "description": "Retrieve the status and generated images for the prompt provided.", + "operationId": "TextImageStatusPost", + "parameters": [ + { + "name": "body", + "in": "body", + "required": false, + "schema": { + "type": "object", + "properties": { + "process_id": { + "type": "string", + "description": "The process identifier.", + "title": "Process ID" + } + }, + "required": [ + "process_id" + ] + } + } + ], + "x-ms-visibility": "important" + } + }, + "/add-image-task": { + "post": { + "responses": { + "200": { + "description": "default", + "schema": { + "type": "object", + "properties": { + "message": { + "type": "string", + "description": "The task message.", + "title": "Message" + }, + "process_id": { + "type": "string", + "description": "The process identifier.", + "title": "Process ID" + } + } + } + } + }, + "summary": "Get image from image", + "description": "Generate an image that resembles an original image provided by you, using Stable Diffusion model.", + "operationId": "ImageImageAddPost", + "parameters": [ + { + "name": "body", + "in": "body", + "required": false, + "schema": { + "type": "object", + "properties": { + "model": { + "type": "string", + "description": "The model.", + "title": "Model", + "x-ms-visibility": "internal", + "default": "img2img" + }, + "data": { + "type": "object", + "properties": { + "prompt": { + "type": "string", + "description": "The prompt.", + "title": "Prompt" + }, + "negprompt": { + "type": "string", + "description": "The negative prompt.", + "title": "Neg Prompt" + }, + "steps": { + "type": "integer", + "format": "int32", + "description": "The steps.", + "title": "Steps" + }, + "guidance_scale": { + "type": "number", + "format": "float", + "description": "The guidance scale.", + "title": "Guidance Scale" + }, + "init_image_url": { + "type": "string", + "description": "The initial image URL address.", + "title": "Init Image URL" + }, + "strength": { + "type": "number", + "format": "float", + "description": "The strength.", + "title": "Strength" + }, + "seed": { + "type": "integer", + "format": "int32", + "description": "The seed.", + "title": "Seed" + } + }, + "title": "Data", + "required": [ + "init_image_url", + "prompt" + ] + } + }, + "required": [ + "model", + "data" + ] + } + } + ], + "x-ms-visibility": "important" + } + }, + "/task-image-status": { + "post": { + "responses": { + "200": { + "description": "default", + "schema": { + "type": "object", + "properties": { + "message": { + "type": "string", + "description": "The task message.", + "title": "Message" + }, + "response_data": { + "type": "object", + "properties": { + "process_id": { + "type": "string", + "description": "The process identifier.", + "title": "Process ID" + }, + "status": { + "type": "string", + "description": "The status.", + "title": "Status" + }, + "result": { + "type": "object", + "properties": { + "output": { + "type": "array", + "items": { + "type": "string" + }, + "description": "The outputs.", + "title": "Outputs" + } + }, + "title": "Result" + }, + "credit_used": { + "type": "integer", + "format": "int32", + "description": "The amount of credit used.", + "title": "Credit Used" + }, + "overage": { + "type": "integer", + "format": "int32", + "description": "The overage.", + "title": "Overage" + } + }, + "title": "Response Data" + } + } + } + } + }, + "summary": "Get image from image status", + "description": "Retrieve the status and generated images for the image and prompt provided.", + "operationId": "ImageImageStatusPost", + "parameters": [ + { + "name": "body", + "in": "body", + "required": false, + "schema": { + "type": "object", + "properties": { + "process_id": { + "type": "string", + "description": "The process identifier.", + "title": "Process ID" + } + }, + "required": [ + "process_id" + ] + } + } + ], + "x-ms-visibility": "important" + } + }, + "/add-edit-task": { + "post": { + "responses": { + "200": { + "description": "default", + "schema": { + "type": "object", + "properties": { + "message": { + "type": "string", + "description": "The task message.", + "title": "Message" + }, + "process_id": { + "type": "string", + "description": "The process identifier.", + "title": "Process ID" + } + } + } + } + }, + "summary": "Edit image", + "description": "Render a new image which has similar style and content to the initial image, but different details and composition, using the Instruct-pix2pix model made by Timothy Brooks.", + "operationId": "ImageEditPost", + "parameters": [ + { + "name": "body", + "in": "body", + "required": false, + "schema": { + "type": "object", + "properties": { + "model": { + "type": "string", + "description": "The model.", + "title": "Model", + "default": "pix2pix", + "x-ms-visibility": "internal" + }, + "data": { + "type": "object", + "properties": { + "prompt": { + "type": "string", + "description": "The prompt.", + "title": "Prompt" + }, + "negprompt": { + "type": "string", + "description": "The negative prompt.", + "title": "Neg Prompt" + }, + "steps": { + "type": "integer", + "format": "int32", + "description": "The steps.", + "title": "Steps" + }, + "guidance_scale": { + "type": "number", + "format": "float", + "description": "The guidance scale.", + "title": "Guidance Scale" + }, + "init_image_url": { + "type": "string", + "description": "The initial image URL address.", + "title": "Init Image URL" + }, + "image_guidance_scale": { + "type": "number", + "format": "float", + "description": "The image guidance scale.", + "title": "Image Guidance Scale" + }, + "seed": { + "type": "integer", + "format": "int32", + "description": "The seed.", + "title": "Seed" + } + }, + "title": "Data", + "required": [ + "prompt", + "init_image_url" + ] + } + }, + "required": [ + "model", + "data" + ] + } + } + ] + } + }, + "/task-edit-status": { + "post": { + "responses": { + "200": { + "description": "default", + "schema": { + "type": "object", + "properties": { + "message": { + "type": "string", + "description": "The task message.", + "title": "Message" + }, + "response_data": { + "type": "object", + "properties": { + "process_id": { + "type": "string", + "description": "The process identifier.", + "title": "Process ID" + }, + "status": { + "type": "string", + "description": "The status.", + "title": "Status" + }, + "result": { + "type": "object", + "properties": { + "output": { + "type": "array", + "items": { + "type": "string" + }, + "description": "The outputs.", + "title": "Outputs" + } + }, + "title": "Result" + }, + "credit_used": { + "type": "integer", + "format": "int32", + "description": "The amount of credit used.", + "title": "Credit Used" + }, + "overage": { + "type": "integer", + "format": "int32", + "description": "The overage.", + "title": "Overage" + } + }, + "title": "Response Data" + } + } + } + } + }, + "summary": "Get edited image status", + "description": "Retrieve the status and generated images for the image and edit prompt provided.", + "operationId": "ImageEditStatusPost", + "parameters": [ + { + "name": "body", + "in": "body", + "required": false, + "schema": { + "type": "object", + "properties": { + "process_id": { + "type": "string", + "description": "The process identifier.", + "title": "Process ID" + } + }, + "required": [ + "process_id" + ] + } + } + ] + } + }, + "/add-audio-task": { + "post": { + "responses": { + "200": { + "description": "default", + "schema": { + "type": "object", + "properties": { + "message": { + "type": "string", + "description": "The task message.", + "title": "Message" + }, + "process_id": { + "type": "string", + "description": "The process identifier.", + "title": "Process ID" + } + } + } + } + }, + "summary": "Get audio file transcription", + "description": "Transcribes any audio file using the OpenAI-Whisper Large-v2 model.", + "operationId": "AudioPost", + "parameters": [ + { + "name": "body", + "in": "body", + "required": false, + "schema": { + "type": "object", + "properties": { + "model": { + "type": "string", + "description": "The model.", + "title": "Model", + "default": "whisper", + "x-ms-visibility": "internal" + }, + "data": { + "type": "object", + "properties": { + "file": { + "type": "string", + "description": "The file.", + "title": "File" + }, + "transcription_format": { + "type": "string", + "description": "The transcription format.", + "title": "Transcription Format", + "enum": [ + "text", + "srt", + "word" + ], + "default": "text" + } + }, + "title": "Data", + "required": [ + "file", + "transcription_format" + ] + } + }, + "required": [ + "model", + "data" + ] + } + } + ] + } + }, + "/task-audio-status": { + "post": { + "responses": { + "200": { + "description": "default", + "schema": { + "type": "object", + "properties": { + "message": { + "type": "string", + "description": "The task message.", + "title": "Message" + }, + "response_data": { + "type": "object", + "properties": { + "process_id": { + "type": "string", + "description": "The process identifier.", + "title": "Process ID" + }, + "status": { + "type": "string", + "description": "The status.", + "title": "Status" + }, + "result": { + "type": "object", + "properties": { + "text": { + "type": "string", + "description": "The text output.", + "title": "Text" + } + }, + "title": "Result" + }, + "credit_used": { + "type": "integer", + "format": "int32", + "description": "The amount of credit used.", + "title": "Credit Used" + }, + "overage": { + "type": "integer", + "format": "int32", + "description": "The overage.", + "title": "Overage" + } + }, + "title": "Response Data" + } + } + } + } + }, + "summary": "Retrieve transcription", + "description": "Retrieve the status and generated text for the audio file provided.", + "operationId": "AudioStatusPost", + "parameters": [ + { + "name": "body", + "in": "body", + "required": false, + "schema": { + "type": "object", + "properties": { + "process_id": { + "type": "string", + "description": "The process identifier.", + "title": "Process ID" + } + }, + "required": [ + "process_id" + ] + } + } + ] + } + } + }, + "definitions": {}, + "parameters": {}, + "responses": {}, + "securityDefinitions": { + "API Key": { + "type": "apiKey", + "in": "header", + "name": "x-api-key" + } + }, + "security": [ + { + "API Key": [] + } + ], + "tags": [], + "x-ms-connector-metadata": [ + { + "propertyName": "Website", + "propertyValue": "https://monsterapi.ai/" + }, + { + "propertyName": "Privacy policy", + "propertyValue": "https://monsterapi.ai/terms-of-service" + }, + { + "propertyName": "Categories", + "propertyValue": "AI" + } + ] +} \ No newline at end of file diff --git a/independent-publisher-connectors/Monster API/apiProperties.json b/independent-publisher-connectors/Monster API/apiProperties.json new file mode 100644 index 000000000..f9de5e5b6 --- /dev/null +++ b/independent-publisher-connectors/Monster API/apiProperties.json @@ -0,0 +1,76 @@ +{ + "properties": { + "connectionParameters": { + "api_key": { + "type": "securestring", + "uiDefinition": { + "displayName": "API Key", + "description": "The API Key for this API.", + "tooltip": "Provide your API Key", + "constraints": { + "tabIndex": 2, + "clearText": false, + "required": "true" + } + } + }, + "token": { + "type": "securestring", + "uiDefinition": { + "displayName": "Token", + "description": "The token for this API.", + "tooltip": "Provide your token", + "constraints": { + "tabIndex": 2, + "clearText": false, + "required": "true" + } + } + } + }, + "iconBrandColor": "#da3b01", + "capabilities": [], + "policyTemplateInstances": [ + { + "templateId": "setheader", + "title": "Add authorization", + "parameters": { + "x-ms-apimTemplateParameter.name": "Authorization", + "x-ms-apimTemplateParameter.value": "Bearer @connectionParameters('token')", + "x-ms-apimTemplateParameter.existsAction": "override", + "x-ms-apimTemplate-policySection": "Request" + } + }, + { + "templateId": "routerequesttoendpoint", + "title": "Route Add", + "parameters": { + "x-ms-apimTemplateParameter.newPath": "/add-task", + "x-ms-apimTemplateParameter.httpMethod": "@Request.OriginalHTTPMethod", + "x-ms-apimTemplate-operationName": [ + "TextImageAddPost", + "ImageImageAddPost", + "ImageEditPost", + "AudioPost" + ] + } + }, + { + "templateId": "routerequesttoendpoint", + "title": "Route Status", + "parameters": { + "x-ms-apimTemplateParameter.newPath": "/task-status", + "x-ms-apimTemplateParameter.httpMethod": "@Request.OriginalHTTPMethod", + "x-ms-apimTemplate-operationName": [ + "TextImageStatusPost", + "ImageImageStatusPost", + "ImageEditStatusPost", + "AudioStatusPost" + ] + } + } + ], + "publisher": "Troy Taylor", + "stackOwner": "Monster API" + } +} \ No newline at end of file diff --git a/independent-publisher-connectors/Monster API/readme.md b/independent-publisher-connectors/Monster API/readme.md new file mode 100644 index 000000000..cd9787601 --- /dev/null +++ b/independent-publisher-connectors/Monster API/readme.md @@ -0,0 +1,31 @@ +# Monster API +With Monster API, you can effortlessly access powerful generative AI models such as Stable Diffusion for text to image and image to image. + +## Publisher: Troy Taylor, Hitachi Solutions + +## Prerequisites +You will need to sign up for an account with [Monster API](https://monsterapi.ai/signup). + +## Obtaining Credentials +Once you are logged in to your dashboard, open the Auth Keys page and create a key to generate an API key and Bearer token. + +## Supported Operations +### Get image from text +Generates an image that looks similar to your provided text prompt using the Stable Diffusion model. +### Get image from text status +Retrieve the status and generated images for the prompt provided. +### Get image from image +Generate an image that resembles an original image provided by you, using Stable Diffusion model. +### Get image from image status +Retrieve the status and generated images for the image and prompt provided. +### Edit image +Render a new image which has similar style and content to the initial image, but different details and composition, using the Instruct-pix2pix model made by Timothy Brooks. +### Get edited image status +Retrieve the status and generated images for the image and edit prompt provided. +### Get audio file transcription +Transcribes any audio file using the OpenAI-Whisper Large-v2 model. +### Retrieve transcription +Retrieve the status and generated text for the audio file provided. + +## Known Issues and Limitations +There are no known issues at this time.