From 0010c10426c987a49ab881c7e698ba22e7cc582e Mon Sep 17 00:00:00 2001 From: Troy Taylor <44444967+troystaylor@users.noreply.github.com> Date: Tue, 20 Sep 2022 16:02:41 -0400 Subject: [PATCH 1/6] Add files via upload --- .../Owlbot/apiDefinition.swagger.json | 120 ++++++++++++++++++ .../Owlbot/apiProperties.json | 23 ++++ .../Owlbot/readme.md | 17 +++ 3 files changed, 160 insertions(+) create mode 100644 independent-publisher-connectors/Owlbot/apiDefinition.swagger.json create mode 100644 independent-publisher-connectors/Owlbot/apiProperties.json create mode 100644 independent-publisher-connectors/Owlbot/readme.md diff --git a/independent-publisher-connectors/Owlbot/apiDefinition.swagger.json b/independent-publisher-connectors/Owlbot/apiDefinition.swagger.json new file mode 100644 index 0000000000..ca3ba79583 --- /dev/null +++ b/independent-publisher-connectors/Owlbot/apiDefinition.swagger.json @@ -0,0 +1,120 @@ +{ + "swagger": "2.0", + "info": { + "title": "Owlbot", + "description": "Owlbot searches the internet to index information and making them accessible. Currently, it offers an English dictionary.", + "version": "1.0", + "contact": { + "name": "Troy Taylor", + "url": "https://www.hitachisolutions.com", + "email": "ttaylor@hitachisolutions.com" + } + }, + "host": "owlbot.info", + "basePath": "/api/v4/dictionary/", + "schemes": [ + "https" + ], + "consumes": [], + "produces": [], + "paths": { + "/{word}": { + "get": { + "responses": { + "200": { + "description": "default", + "schema": { + "type": "object", + "properties": { + "word": { + "type": "string", + "description": "The word.", + "title": "word" + }, + "pronunciation": { + "type": "string", + "description": "The pronunciation.", + "title": "pronunciation" + }, + "definitions": { + "type": "array", + "items": { + "type": "object", + "properties": { + "type": { + "type": "string", + "description": "The type.", + "title": "type" + }, + "definition": { + "type": "string", + "description": "The definition.", + "title": "definition" + }, + "example": { + "type": "string", + "description": "The example.", + "title": "example" + }, + "image_url": { + "type": "string", + "description": "The image URL address.", + "title": "image_url" + }, + "emoji": { + "type": "string", + "description": "The emoji.", + "title": "emoji" + } + } + }, + "title": "definitions" + } + } + } + } + }, + "summary": "Get a definition", + "description": "Retrieves the definition of a word, as well as pronunciation, picture, example sentence, and emoji if available.", + "operationId": "Def", + "parameters": [ + { + "name": "word", + "in": "path", + "x-ms-summary": "Word", + "x-ms-url-encoding": "single", + "description": "The word to define.", + "required": true, + "type": "string" + } + ] + } + } + }, + "definitions": {}, + "parameters": {}, + "responses": {}, + "securityDefinitions": { + "api_key": { + "type": "apiKey", + "in": "header", + "name": "Authorization" + } + }, + "security": [], + "tags": [], + "x-ms-connector-metadata": [ + { + "propertyName": "Website", + "propertyValue": "https://owlbot.info/" + }, + { + "propertyName": "Privacy policy", + "propertyValue": "https://owlbot.info/" + }, + { + "propertyName": "Categories", + "propertyValue": "Data" + } + ] +} \ No newline at end of file diff --git a/independent-publisher-connectors/Owlbot/apiProperties.json b/independent-publisher-connectors/Owlbot/apiProperties.json new file mode 100644 index 0000000000..8061d3fc6e --- /dev/null +++ b/independent-publisher-connectors/Owlbot/apiProperties.json @@ -0,0 +1,23 @@ +{ + "properties": { + "connectionParameters": { + "api_key": { + "type": "securestring", + "uiDefinition": { + "displayName": "API Token (in the format 'Token Your_Token')", + "description": "The API Token (in the format 'Token Your_Token') for this api", + "tooltip": "Provide your API Token (in the format 'Token Your_Token')", + "constraints": { + "tabIndex": 2, + "clearText": false, + "required": "true" + } + } + } + }, + "iconBrandColor": "#da3b01", + "capabilities": [], + "publisher": "Troy Taylor", + "stackOwner": "Owlbot" + } +} \ No newline at end of file diff --git a/independent-publisher-connectors/Owlbot/readme.md b/independent-publisher-connectors/Owlbot/readme.md new file mode 100644 index 0000000000..24963a0598 --- /dev/null +++ b/independent-publisher-connectors/Owlbot/readme.md @@ -0,0 +1,17 @@ +# Owlbot +Owlbot searches the internet to index information and making them accessible. Currently, it offers an English dictionary. + +## Publisher: Troy Taylor, Hitachi Solutions + +## Prerequisites +There are no prerequisites to use this service. + +## Obtaining Credentials +You will need to request an API token on the [Owlbot website](https://owlbot.info/). + +## Supported Operations +### Get a definition +Retrieves the definition of a word, as well as pronunciation, picture, example sentence, and emoji if available. + +## Known Issues and Limitations +There are no known issues at this time. From 06370dbbf9c4260f5d0ea6c647a01797ec70c523 Mon Sep 17 00:00:00 2001 From: Troy Taylor <44444967+troystaylor@users.noreply.github.com> Date: Mon, 10 Oct 2022 14:11:49 -0400 Subject: [PATCH 2/6] Add files via upload --- .../Tree-Nation/apiDefinition.swagger.json | 1042 +++++++++++++++++ .../Tree-Nation/apiProperties.json | 23 + .../Tree-Nation/readme.md | 39 + 3 files changed, 1104 insertions(+) create mode 100644 independent-publisher-connectors/Tree-Nation/apiDefinition.swagger.json create mode 100644 independent-publisher-connectors/Tree-Nation/apiProperties.json create mode 100644 independent-publisher-connectors/Tree-Nation/readme.md diff --git a/independent-publisher-connectors/Tree-Nation/apiDefinition.swagger.json b/independent-publisher-connectors/Tree-Nation/apiDefinition.swagger.json new file mode 100644 index 0000000000..beaea454c2 --- /dev/null +++ b/independent-publisher-connectors/Tree-Nation/apiDefinition.swagger.json @@ -0,0 +1,1042 @@ +{ + "swagger": "2.0", + "info": { + "version": "1.0", + "title": "Tree-Nation", + "description": "The simplest way for citizens and companies to plant trees around the world and offset their CO2 emissions. Tree-Nation is on a mission to plant 1 trillion trees by 2050.", + "contact": { + "name": "Troy Taylor", + "url": "https://www.hitachisolutions.com", + "email": "ttaylor@hitachisolutions.com" + } + }, + "host": "tree-nation.com", + "basePath": "/", + "schemes": [ + "https" + ], + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "paths": { + "/api/projects": { + "get": { + "summary": "Project list", + "description": "Retrieve all projects. If the parameter status=active is passed, only active projects (those where a tree can be planted) will be listed.", + "operationId": "ProjectList", + "parameters": [ + { + "name": "status", + "default": "active", + "in": "query", + "x-ms-summary": "Status", + "description": "The status.", + "type": "string", + "required": true + } + ], + "responses": { + "200": { + "description": "200", + "schema": { + "type": "array", + "items": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "format": "int32", + "description": "The identifier.", + "title": "ID" + }, + "name": { + "type": "string", + "description": "The name.", + "title": "Name" + }, + "description": { + "type": "string", + "description": "The description.", + "title": "Description" + }, + "slug": { + "type": "string", + "description": "The slug.", + "title": "Slug" + }, + "location": { + "type": "string", + "description": "The location.", + "title": "Location" + }, + "lat": { + "type": "number", + "format": "float", + "description": "The latitude.", + "title": "Latitude" + }, + "long": { + "type": "number", + "format": "float", + "description": "The longitude.", + "title": "Longitude" + }, + "status": { + "type": "string", + "description": "The status.", + "title": "Status" + }, + "url": { + "type": "string", + "description": "The URL address.", + "title": "URL" + }, + "species_price_from": { + "type": "number", + "format": "float", + "description": "The species price from.", + "title": "Species Price From" + } + } + } + } + } + } + } + }, + "/api/projects/{project_id}": { + "get": { + "summary": "Project details", + "description": "Retrieve the details about a project.", + "operationId": "ProjectDetails", + "parameters": [ + { + "name": "project_id", + "in": "path", + "x-ms-summary": "Project ID", + "x-ms-url-encoding": "single", + "description": "The project identifier.", + "type": "string", + "required": true + } + ], + "responses": { + "200": { + "description": "200", + "schema": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "format": "int32", + "description": "The identifier.", + "title": "ID" + }, + "name": { + "type": "string", + "description": "The name.", + "title": "Name" + }, + "description": { + "type": "string", + "description": "The description.", + "title": "Description" + }, + "image": { + "type": "string", + "description": "The image.", + "title": "Image" + }, + "slug": { + "type": "string", + "description": "The slug.", + "title": "Slug" + }, + "location": { + "type": "string", + "description": "The location.", + "title": "Location" + }, + "lat": { + "type": "number", + "format": "float", + "description": "The latitude.", + "title": "Latitude" + }, + "long": { + "type": "number", + "format": "float", + "description": "The longitude.", + "title": "Longitude" + }, + "status": { + "type": "string", + "description": "The status.", + "title": "Status" + }, + "url": { + "type": "string", + "description": "The URL address.", + "title": "URL" + }, + "species_price_from": { + "type": "number", + "format": "float", + "description": "The species price from.", + "title": "Species Price From" + } + } + } + } + } + } + }, + "/api/projects/{project_id}/planting-sites": { + "get": { + "summary": "Sites list", + "description": "Retrieve the available planting sites in a project.", + "operationId": "SitesList", + "parameters": [ + { + "name": "project_id", + "in": "path", + "x-ms-summary": "Project ID", + "x-ms-url-encoding": "single", + "description": "The project identifier.", + "type": "string", + "required": true + } + ], + "responses": { + "200": { + "description": "200", + "schema": { + "type": "array", + "items": { + "type": "object", + "properties": { + "address": { + "type": "string", + "description": "The address.", + "title": "Address" + }, + "created_at": { + "type": "string", + "description": "When created at.", + "title": "Created At" + }, + "description": { + "type": "string", + "description": "The description.", + "title": "Description" + }, + "id": { + "type": "integer", + "format": "int32", + "description": "The identifier.", + "title": "ID" + }, + "image": { + "type": "string", + "description": "The image.", + "title": "Image" + }, + "name": { + "type": "string", + "description": "The name.", + "title": "Name" + }, + "polygon_data": { + "type": "string", + "description": "The polygon data.", + "title": "Polygon Data" + }, + "project_id": { + "type": "integer", + "format": "int32", + "description": "The project identifier.", + "title": "Project ID" + }, + "slug": { + "type": "string", + "description": "The slug.", + "title": "Slug" + } + } + } + } + } + } + } + }, + "/api/projects/{project_id}/species": { + "get": { + "summary": "Species list", + "description": "Retrieve the available species in a project. Only those species with stock > 0 can be used for planting.", + "operationId": "SpeciesList", + "parameters": [ + { + "name": "project_id", + "in": "path", + "x-ms-summary": "Project ID", + "x-ms-url-encoding": "single", + "description": "The project identifier.", + "type": "string", + "required": true + } + ], + "responses": { + "200": { + "description": "200", + "schema": { + "type": "array", + "items": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "format": "int32", + "description": "The identifier.", + "title": "ID" + }, + "project_id": { + "type": "integer", + "format": "int32", + "description": "The project identifier.", + "title": "Project ID" + }, + "name": { + "type": "string", + "description": "The name.", + "title": "Name" + }, + "life_time_CO2": { + "type": "integer", + "format": "int32", + "description": "The lifetime CO2.", + "title": "Lifetime CO2" + }, + "price": { + "type": "integer", + "format": "int32", + "description": "The price.", + "title": "Price" + }, + "stock": { + "type": "integer", + "format": "int32", + "description": "The stock.", + "title": "Stock" + } + } + } + } + } + } + } + }, + "/api/species/{species_id}": { + "get": { + "summary": "Species details", + "description": "Retrieve the details about a species.", + "operationId": "SpeciesDetails", + "parameters": [ + { + "name": "species_id", + "in": "path", + "x-ms-summary": "Species ID", + "x-ms-url-encoding": "single", + "description": "The species identifier.", + "type": "string", + "required": true + } + ], + "responses": { + "200": { + "description": "200", + "schema": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "format": "int32", + "description": "The identifier.", + "title": "ID" + }, + "project_id": { + "type": "integer", + "format": "int32", + "description": "The project ID.", + "title": "Project ID" + }, + "name": { + "type": "string", + "description": "The name.", + "title": "Name" + }, + "life_time_CO2": { + "type": "integer", + "format": "int32", + "description": "The lifetime CO2.", + "title": "Lifetime CO2" + }, + "price": { + "type": "integer", + "format": "int32", + "description": "The price.", + "title": "Price" + }, + "common_names": { + "type": "string", + "description": "The common name.", + "title": "Common Names" + }, + "image": { + "type": "string", + "description": "The image.", + "title": "Image" + }, + "family": { + "type": "string", + "description": "The family.", + "title": "Family" + }, + "particularities": { + "type": "string", + "description": "The particularities.", + "title": "Particularities" + }, + "planter_likes": { + "type": "string", + "description": "The planter likes.", + "title": "Planter Likes" + }, + "height": { + "type": "string", + "description": "The height.", + "title": "Height" + }, + "average_natural_life_span": { + "type": "integer", + "format": "int32", + "description": "The average natural life span.", + "title": "Average Natural Life Span" + }, + "co2_offset": { + "type": "integer", + "format": "int32", + "description": "The CO2 offset.", + "title": "CO2 Offset" + }, + "co2_offset_period": { + "type": "string", + "description": "The CO2 offset period.", + "title": "CO2 Offset Period" + }, + "stock": { + "type": "integer", + "format": "int32", + "description": "The stock.", + "title": "Stock" + }, + "category": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "format": "int32", + "description": "The identifier.", + "title": "ID" + }, + "name": { + "type": "string", + "description": "The name.", + "title": "Name" + } + }, + "title": "Category" + }, + "foliage": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "format": "int32", + "description": "The identifier.", + "title": "ID" + }, + "name": { + "type": "string", + "description": "The name.", + "title": "Name" + } + }, + "title": "Foliage" + }, + "origin_type": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "format": "int32", + "description": "The identifier.", + "title": "ID" + }, + "name": { + "type": "string", + "description": "The name.", + "title": "Name" + } + }, + "title": "Origin Type" + } + } + } + } + } + } + }, + "/api/forests/{user_id}": { + "get": { + "summary": "Forest details", + "description": "Retrieve a user forest details", + "operationId": "ForestDetails", + "parameters": [ + { + "name": "user_id", + "in": "path", + "x-ms-summary": "User ID", + "x-ms-url-encoding": "single", + "description": "The user identifier.", + "type": "string", + "required": true + } + ], + "responses": { + "200": { + "description": "200", + "schema": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "format": "int32", + "description": "The identifier.", + "title": "ID" + }, + "co2_compensated": { + "type": "number", + "format": "float", + "description": "The CO2 compensated.", + "title": "CO2 Compensated" + }, + "tree_count": { + "type": "string", + "description": "The tree count.", + "title": "Tree Count" + } + } + } + } + } + } + }, + "/api/forests/{user_slug}/tree_counter/{period}": { + "get": { + "summary": "Forest tree count", + "description": "Retrieve a user forest tree count (by slug). Period is optional and can be one of: day, week, month, quarter, year. If period is not passed, the all time value will be returned.", + "operationId": "ForestTreeCount", + "parameters": [ + { + "name": "user_slug", + "in": "path", + "x-ms-summary": "user slug", + "x-ms-url-encoding": "single", + "description": "The user slug.", + "type": "string", + "required": true + }, + { + "name": "period", + "in": "path", + "x-ms-summary": "Period", + "x-ms-url-encoding": "single", + "description": "The period.", + "type": "string", + "required": true + } + ], + "responses": { + "200": { + "description": "200", + "schema": { + "type": "object", + "properties": { + "count": { + "type": "integer", + "format": "int32", + "description": "The count.", + "title": "Count" + } + } + } + } + } + } + }, + "/api/plant": { + "post": { + "summary": "Plant", + "description": "Plant a tree.", + "operationId": "Plant", + "parameters": [ + { + "name": "body", + "in": "body", + "schema": { + "type": "object", + "properties": { + "recipients": { + "type": "array", + "items": { + "type": "object", + "properties": { + "name": { + "type": "string", + "description": "The name.", + "title": "Name" + }, + "email": { + "type": "string", + "description": "The email address.", + "title": "Email" + } + } + }, + "title": "Recipients" + }, + "planter_id": { + "type": "integer", + "format": "int32", + "description": "The planter identifier.", + "title": "Planter ID" + }, + "species_id": { + "type": "integer", + "format": "int32", + "description": "The species identifier.", + "title": "Species ID" + }, + "quantity": { + "type": "integer", + "format": "int32", + "description": "The quantity.", + "title": "Quantity" + }, + "message": { + "type": "string", + "description": "The message.", + "title": "Message" + } + } + }, + "required": true + } + ], + "responses": { + "200": { + "description": "200", + "schema": { + "type": "object", + "properties": { + "status": { + "type": "string", + "description": "The status.", + "title": "Status" + }, + "trees": { + "type": "array", + "items": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "format": "int32", + "description": "The identifier.", + "title": "ID" + }, + "token": { + "type": "string", + "description": "The token.", + "title": "Token" + }, + "collect_url": { + "type": "string", + "description": "The collection URL address.", + "title": "Collect URL" + }, + "certificate_url": { + "type": "string", + "description": "The certificate URL address.", + "title": "Certificate URL" + } + } + }, + "title": "Trees" + }, + "payment_id": { + "type": "integer", + "format": "int32", + "description": "The payment identifier.", + "title": "Payment ID" + } + } + } + } + } + } + }, + "/api/user/b2b": { + "put": { + "summary": "Create user", + "description": "Create a new user.", + "operationId": "CreateUser", + "parameters": [ + { + "name": "body", + "in": "body", + "schema": { + "type": "object", + "properties": { + "name": { + "type": "string", + "description": "The name.", + "title": "Name" + }, + "email": { + "type": "string", + "description": "The email address.", + "title": "Email" + }, + "language": { + "type": "string", + "description": "The language.", + "title": "Language" + }, + "password": { + "type": "string", + "description": "The password.", + "title": "Password" + }, + "responsible_name": { + "type": "string", + "description": "The responsible name.", + "title": "Responsible Name" + }, + "organization_website": { + "type": "string", + "description": "The organization website.", + "title": "Organization Website" + } + } + }, + "required": true + } + ], + "responses": { + "200": { + "description": "200", + "schema": { + "type": "object", + "properties": { + "status": { + "type": "string", + "description": "The status.", + "title": "Status" + }, + "user_id": { + "type": "integer", + "format": "int32", + "description": "The user identifier.", + "title": "User ID" + }, + "password": { + "type": "string", + "description": "The password.", + "title": "Password" + }, + "slug": { + "type": "string", + "description": "The slug.", + "title": "Slug" + }, + "forest_url": { + "type": "string", + "description": "The forest URL address.", + "title": "Forest URL" + } + } + } + } + } + } + }, + "/api/tree_templates/{planter_id}": { + "get": { + "summary": "Tree template details", + "description": "Retrieve the details about the tree template of a planter.", + "operationId": "TreeTemplateDetails", + "parameters": [ + { + "name": "planter_id", + "in": "path", + "x-ms-summary": "Planter ID", + "x-ms-url-encoding": "single", + "description": "The planter identifier.", + "type": "string", + "required": true + } + ], + "responses": { + "200": { + "description": "200", + "schema": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "format": "int32", + "description": "The identifier.", + "title": "ID" + }, + "planter_id": { + "type": "integer", + "format": "int32", + "description": "The planter identifier.", + "title": "Planter ID" + }, + "message": { + "type": "string", + "description": "The message.", + "title": "Message" + }, + "image": { + "type": "string", + "description": "The image.", + "title": "Image" + }, + "video": { + "type": "string", + "description": "The video.", + "title": "Video" + }, + "species_id": { + "type": "integer", + "format": "int32", + "description": "The species identifier.", + "title": "Species ID" + }, + "package_quantity": { + "type": "integer", + "format": "int32", + "description": "The package quantity.", + "title": "Package Quantity" + }, + "price_per_tree": { + "type": "integer", + "format": "int32", + "description": "The price per tree.", + "title": "Price Per Tree" + }, + "total_price": { + "type": "integer", + "format": "int32", + "description": "The total price.", + "title": "Total Price" + } + } + } + } + } + }, + "post": { + "summary": "Update tree template", + "description": "Modify the message of a tree template.", + "operationId": "UpdateTreeTemplate", + "parameters": [ + { + "name": "planter_id", + "in": "path", + "x-ms-summary": "Planter ID", + "x-ms-url-encoding": "single", + "description": "The planter identifier.", + "type": "string", + "required": true + }, + { + "name": "body", + "in": "body", + "schema": { + "type": "object", + "properties": { + "message": { + "type": "string", + "description": "The message.", + "title": "Message" + } + } + }, + "required": true + } + ], + "responses": { + "200": { + "description": "200", + "schema": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "format": "int32", + "description": "The identifier.", + "title": "ID" + }, + "planter_id": { + "type": "integer", + "format": "int32", + "description": "The planter identifier.", + "title": "Planter ID" + }, + "video": { + "type": "string", + "description": "The video.", + "title": "Video" + }, + "species_id": { + "type": "integer", + "format": "int32", + "description": "The species identifier.", + "title": "Species ID" + }, + "package_quantity": { + "type": "integer", + "format": "int32", + "description": "The package quantity.", + "title": "Package Quantity" + }, + "price_per_tree": { + "type": "integer", + "format": "int32", + "description": "The price per tree.", + "title": "Price Per Tree" + }, + "total_price": { + "type": "integer", + "format": "int32", + "description": "The total price.", + "title": "Total Price" + }, + "message": { + "type": "string", + "description": "The message.", + "title": "Message" + }, + "image": { + "type": "string", + "description": "The image.", + "title": "Image" + } + } + } + } + } + } + }, + "/api/credit": { + "post": { + "summary": "Buy credit", + "description": "Buy credit.", + "operationId": "BuyCredit", + "parameters": [ + { + "name": "body", + "in": "body", + "schema": { + "type": "object", + "properties": { + "planter_id": { + "type": "integer", + "format": "int32", + "description": "The planter identifier.", + "title": "Planter ID" + }, + "amount": { + "type": "integer", + "format": "int32", + "description": "The amount.", + "title": "Amount" + } + } + }, + "required": true + } + ], + "responses": { + "200": { + "description": "200", + "schema": { + "type": "object", + "properties": { + "status": { + "type": "string", + "description": "The status.", + "title": "Status" + }, + "payment_id": { + "type": "integer", + "format": "int32", + "description": "The payment identifier.", + "title": "Payment ID" + } + } + } + } + } + } + } + }, + "definitions": {}, + "parameters": {}, + "responses": {}, + "securityDefinitions": { + "API Key": { + "type": "apiKey", + "in": "header", + "name": "Authorization" + } + }, + "security": [ + { + "API Key": [] + } + ], + "tags": [], + "x-ms-connector-metadata": [ + { + "propertyName": "Website", + "propertyValue": "https://tree-nation.com/" + }, + { + "propertyName": "Privacy policy", + "propertyValue": "https://tree-nation.com/legal/privacy-policy" + }, + { + "propertyName": "Categories", + "propertyValue": "Lifestyle and Entertainment" + } + ] + +} \ No newline at end of file diff --git a/independent-publisher-connectors/Tree-Nation/apiProperties.json b/independent-publisher-connectors/Tree-Nation/apiProperties.json new file mode 100644 index 0000000000..45a7a3a182 --- /dev/null +++ b/independent-publisher-connectors/Tree-Nation/apiProperties.json @@ -0,0 +1,23 @@ +{ + "properties": { + "connectionParameters": { + "api_key": { + "type": "securestring", + "uiDefinition": { + "displayName": "API Key (in the form 'Bearer API_Token')", + "description": "The API Key (in the form 'Bearer API_Token') for this api", + "tooltip": "Provide your API Key (in the form 'Bearer API_Token')", + "constraints": { + "tabIndex": 2, + "clearText": false, + "required": "true" + } + } + } + }, + "iconBrandColor": "#da3b01", + "capabilities": [], + "publisher": "Troy Taylor", + "stackOwner": "Tree-Nation" + } +} \ No newline at end of file diff --git a/independent-publisher-connectors/Tree-Nation/readme.md b/independent-publisher-connectors/Tree-Nation/readme.md new file mode 100644 index 0000000000..08a23ec3dc --- /dev/null +++ b/independent-publisher-connectors/Tree-Nation/readme.md @@ -0,0 +1,39 @@ +# Tree-Nation +The simplest way for citizens and companies to plant trees around the world and offset their CO2 emissions. Tree-Nation is on a mission to plant 1 trillion trees by 2050. + +## Publisher: Troy Taylor, Hitachi Solutions + +## Prerequisites +You will need to create an account with [Tree-Nation](https://tree-nation.com/) and request access to the API. + +## Obtaining Credentials +Tree-Nation will email you an API token to use when your API access has been approved. + +## Supported Operations +### Project list +If the parameter status=active is passed, only active projects (those where a tree can be planted) will be listed. +### Project details +Retrieve the details about a project. +### Sites list +Retrieve the available planting sites in a project. +### Species list +Retrieve the available species in a project. Only those species with stock > 0 can be used for planting. +### Species details +Retrieve the details about a species. +### Forest details +Retrieve a user forest details. +### Forest tree count +Retrieve a user forest tree count (by slug). Period is optional and can be one of: day, week, month, quarter, year. If period is not passed, the all time value will be returned. +### Plant +Plant a tree. +### Create user +Create a new user. +### Tree template details +Retrieve the details about the tree template of a planter. +### Update tree template +Modify the message of a tree template. +### Buy credit +Buy credit. + +## Known Issues and Limitations +There are no known issues at this time. From d18fd3576afe77a091f3e205a8025bd83fb179c2 Mon Sep 17 00:00:00 2001 From: Troy Taylor <44444967+troystaylor@users.noreply.github.com> Date: Wed, 30 Nov 2022 15:33:06 -0500 Subject: [PATCH 3/6] Add files via upload --- .../apiDefinition.swagger.json | 417 ++++++++++++++++++ .../Today in History/apiProperties.json | 9 + .../Today in History/readme.md | 19 + 3 files changed, 445 insertions(+) create mode 100644 independent-publisher-connectors/Today in History/apiDefinition.swagger.json create mode 100644 independent-publisher-connectors/Today in History/apiProperties.json create mode 100644 independent-publisher-connectors/Today in History/readme.md diff --git a/independent-publisher-connectors/Today in History/apiDefinition.swagger.json b/independent-publisher-connectors/Today in History/apiDefinition.swagger.json new file mode 100644 index 0000000000..244dad5eb9 --- /dev/null +++ b/independent-publisher-connectors/Today in History/apiDefinition.swagger.json @@ -0,0 +1,417 @@ +{ + "swagger": "2.0", + "info": { + "title": "Today in History", + "description": "Today in History retrieves some basic historical information for any given day. All date entries are parsed from Wikipedia.", + "version": "1.0", + "contact": { + "name": "Troy Taylor", + "url": "https://www.hitachisolutions.com", + "email": "ttaylor@hitachisolutions.com" + } + }, + "host": "history.muffinlabs.com", + "basePath": "/", + "schemes": [ + "https" + ], + "consumes": [], + "produces": [], + "paths": { + "/date": { + "get": { + "responses": { + "200": { + "description": "default", + "schema": { + "type": "object", + "properties": { + "date": { + "type": "string", + "description": "The date.", + "title": "Date" + }, + "url": { + "type": "string", + "description": "The Wikipedia URL address.", + "title": "URL" + }, + "data": { + "type": "object", + "properties": { + "Events": { + "type": "array", + "items": { + "type": "object", + "properties": { + "year": { + "type": "string", + "description": "The year.", + "title": "Year" + }, + "text": { + "type": "string", + "description": "The event text.", + "title": "Text" + }, + "html": { + "type": "string", + "description": "The HTML.", + "title": "HTML" + }, + "no_year_html": { + "type": "string", + "description": "The no year HTML.", + "title": "No Year HTML" + }, + "links": { + "type": "array", + "items": { + "type": "object", + "properties": { + "title": { + "type": "string", + "description": "The title.", + "title": "Title" + }, + "link": { + "type": "string", + "description": "The link address.", + "title": "Link" + } + } + }, + "title": "Links" + } + } + }, + "title": "Events" + }, + "Births": { + "type": "array", + "items": { + "type": "object", + "properties": { + "year": { + "type": "string", + "description": "The year.", + "title": "Year" + }, + "text": { + "type": "string", + "description": "The event text.", + "title": "Text" + }, + "html": { + "type": "string", + "description": "The HTML.", + "title": "HTML" + }, + "no_year_html": { + "type": "string", + "description": "The no year HTML.", + "title": "No Year HTML" + }, + "links": { + "type": "array", + "items": { + "type": "object", + "properties": { + "title": { + "type": "string", + "description": "The title.", + "title": "Title" + }, + "link": { + "type": "string", + "description": "The link address.", + "title": "Link" + } + } + }, + "title": "Links" + } + } + }, + "title": "Births" + }, + "Deaths": { + "type": "array", + "items": { + "type": "object", + "properties": { + "year": { + "type": "string", + "description": "The year.", + "title": "Year" + }, + "text": { + "type": "string", + "description": "The event text.", + "title": "Text" + }, + "html": { + "type": "string", + "description": "The HTML.", + "title": "HTML" + }, + "no_year_html": { + "type": "string", + "description": "The no year HTML.", + "title": "No Year HTML" + }, + "links": { + "type": "array", + "items": { + "type": "object", + "properties": { + "title": { + "type": "string", + "description": "The title.", + "title": "Title" + }, + "link": { + "type": "string", + "description": "The link address.", + "title": "Link" + } + } + }, + "title": "Links" + } + } + }, + "title": "Deaths" + } + }, + "title": "Data" + } + } + } + } + }, + "summary": "Get events for today", + "description": "Retrieve a list of events that happened on this day in history.", + "operationId": "TodayGet", + "parameters": [] + } + }, + "/date/{month}/{day}": { + "get": { + "responses": { + "200": { + "description": "default", + "schema": { + "type": "object", + "properties": { + "date": { + "type": "string", + "description": "The date.", + "title": "Date" + }, + "url": { + "type": "string", + "description": "The Wikipedia URL address.", + "title": "URL" + }, + "data": { + "type": "object", + "properties": { + "Events": { + "type": "array", + "items": { + "type": "object", + "properties": { + "year": { + "type": "string", + "description": "The year.", + "title": "Year" + }, + "text": { + "type": "string", + "description": "The event text.", + "title": "Text" + }, + "html": { + "type": "string", + "description": "The HTML.", + "title": "HTML" + }, + "no_year_html": { + "type": "string", + "description": "The no year HTML.", + "title": "No Year HTML" + }, + "links": { + "type": "array", + "items": { + "type": "object", + "properties": { + "title": { + "type": "string", + "description": "The title.", + "title": "Title" + }, + "link": { + "type": "string", + "description": "The link address.", + "title": "Link" + } + } + }, + "title": "Links" + } + } + }, + "title": "Events" + }, + "Births": { + "type": "array", + "items": { + "type": "object", + "properties": { + "year": { + "type": "string", + "description": "The year.", + "title": "Year" + }, + "text": { + "type": "string", + "description": "The event text.", + "title": "Text" + }, + "html": { + "type": "string", + "description": "The HTML.", + "title": "HTML" + }, + "no_year_html": { + "type": "string", + "description": "The no year HTML.", + "title": "No Year HTML" + }, + "links": { + "type": "array", + "items": { + "type": "object", + "properties": { + "title": { + "type": "string", + "description": "The title.", + "title": "Title" + }, + "link": { + "type": "string", + "description": "The link address.", + "title": "Link" + } + } + }, + "title": "Links" + } + } + }, + "title": "Births" + }, + "Deaths": { + "type": "array", + "items": { + "type": "object", + "properties": { + "year": { + "type": "string", + "description": "The year.", + "title": "Year" + }, + "text": { + "type": "string", + "description": "The event text.", + "title": "Text" + }, + "html": { + "type": "string", + "description": "The HTML.", + "title": "HTML" + }, + "no_year_html": { + "type": "string", + "description": "The no year HTML.", + "title": "No Year HTML" + }, + "links": { + "type": "array", + "items": { + "type": "object", + "properties": { + "title": { + "type": "string", + "description": "The title.", + "title": "Title" + }, + "link": { + "type": "string", + "description": "The link address.", + "title": "Link" + } + } + }, + "title": "Links" + } + } + }, + "title": "Deaths" + } + }, + "title": "Data" + } + } + } + } + }, + "summary": "Get events for a different day", + "description": "Retrieve a list of events that happened on a specific day in history.", + "operationId": "DayGet", + "parameters": [ + { + "name": "month", + "in": "path", + "x-ms-url-encoding": "single", + "required": true, + "type": "string", + "description": "The month in M format.", + "x-ms-summary": "Month" + }, + { + "name": "day", + "in": "path", + "x-ms-url-encoding": "single", + "required": true, + "type": "string", + "description": "The day in the D format.", + "x-ms-summary": "Day" + } + ] + } + } + }, + "definitions": {}, + "parameters": {}, + "responses": {}, + "securityDefinitions": {}, + "security": [], + "tags": [], + "x-ms-connector-metadata": [ + { + "propertyName": "Website", + "propertyValue": "https://history.muffinlabs.com/" + }, + { + "propertyName": "Privacy policy", + "propertyValue": "https://history.muffinlabs.com/" + }, + { + "propertyName": "Categories", + "propertyValue": "Lifestyle and Entertainment" + } + ] +} \ No newline at end of file diff --git a/independent-publisher-connectors/Today in History/apiProperties.json b/independent-publisher-connectors/Today in History/apiProperties.json new file mode 100644 index 0000000000..20f47f46a4 --- /dev/null +++ b/independent-publisher-connectors/Today in History/apiProperties.json @@ -0,0 +1,9 @@ +{ + "properties": { + "connectionParameters": {}, + "iconBrandColor": "#da3b01", + "capabilities": [], + "publisher": "Troy Taylor", + "stackOwner": "muffinlabs" + } +} \ No newline at end of file diff --git a/independent-publisher-connectors/Today in History/readme.md b/independent-publisher-connectors/Today in History/readme.md new file mode 100644 index 0000000000..f70d7ed68a --- /dev/null +++ b/independent-publisher-connectors/Today in History/readme.md @@ -0,0 +1,19 @@ +# Today in History +Today in History retrieves some basic historical information for any given day. All date entries are parsed from Wikipedia. + +## Publisher: Troy Taylor, Hitachi Solutions + +## Prerequisites +There are no prerequisites to use this service. + +## Obtaining Credentials +There are no credentials needed to use this service. + +## Supported Operations +### Get events for today +Retrieve a list of events that happened on this day in history. +### Get events for a different day +Retrieve a list of events that happened on a specific day in history. + +## Known Issues and Limitations +There are no known issues at this time. From 74c8fb0db98a9c0a8a72776548bcaef53032b462 Mon Sep 17 00:00:00 2001 From: Troy Taylor <44444967+troystaylor@users.noreply.github.com> Date: Fri, 10 Mar 2023 16:18:31 -0500 Subject: [PATCH 4/6] Add files via upload --- .../Cohere/apiDefinition.swagger.json | 847 ++++++++++++++++++ .../Cohere/apiProperties.json | 35 + .../Cohere/readme.md | 29 + 3 files changed, 911 insertions(+) create mode 100644 independent-publisher-connectors/Cohere/apiDefinition.swagger.json create mode 100644 independent-publisher-connectors/Cohere/apiProperties.json create mode 100644 independent-publisher-connectors/Cohere/readme.md diff --git a/independent-publisher-connectors/Cohere/apiDefinition.swagger.json b/independent-publisher-connectors/Cohere/apiDefinition.swagger.json new file mode 100644 index 0000000000..f6972cd9a4 --- /dev/null +++ b/independent-publisher-connectors/Cohere/apiDefinition.swagger.json @@ -0,0 +1,847 @@ +{ + "swagger": "2.0", + "info": { + "title": "Cohere", + "description": "Cohere is making natural language processing part of every developer's toolkit. Harness the power of language understanding. Join the developers and businesses who are using Cohere to generate, categorize and organize text at a scale that was previously unimaginable.", + "version": "1.0", + "contact": { + "name": "Troy Taylor", + "url": "https://www.hitachisolutions.com", + "email": "ttaylor@hitachisolutions.com" + } + }, + "host": "api.cohere.ai", + "basePath": "/", + "schemes": [ + "https" + ], + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "paths": { + "/generate": { + "post": { + "responses": { + "200": { + "description": "default", + "schema": { + "type": "object", + "properties": { + "id": { + "type": "string", + "description": "The identifier.", + "title": "ID" + }, + "generations": { + "type": "array", + "items": { + "type": "object", + "properties": { + "id": { + "type": "string", + "description": "The identifier.", + "title": "ID" + }, + "text": { + "type": "string", + "description": "The text.", + "title": "Text" + } + } + }, + "title": "Generations" + }, + "prompt": { + "type": "string", + "description": "The prompt.", + "title": "Prompt" + } + } + } + } + }, + "summary": "Generate text", + "description": "This action generates realistic text conditioned on a given input.", + "operationId": "GeneratePost", + "parameters": [ + { + "name": "body", + "in": "body", + "required": false, + "schema": { + "type": "object", + "properties": { + "prompt": { + "type": "string", + "description": "The prompt.", + "title": "Prompt" + }, + "model": { + "type": "string", + "description": "The model.", + "title": "Model", + "enum": [ + "medium", + "xlarge" + ] + }, + "num_generations": { + "type": "integer", + "format": "int32", + "description": "The number of generations.", + "title": "Num Generations", + "default": 1, + "minimum": 1, + "maximum": 5 + }, + "max_tokens": { + "type": "integer", + "format": "int32", + "description": "The maximum number of tokens.", + "title": "Max Tokens" + }, + "preset": { + "type": "string", + "description": "The preset.", + "title": "Preset" + }, + "temperature": { + "type": "number", + "format": "float", + "description": "The temperature.", + "title": "Temperature" + }, + "k": { + "type": "integer", + "format": "int32", + "description": "The k value.", + "title": "k", + "default": 0, + "minimum": 0, + "maximum": 500 + }, + "p": { + "type": "number", + "format": "float", + "description": "The p value.", + "title": "p", + "default": 0.75 + }, + "frequency_penalty": { + "type": "number", + "format": "float", + "description": "The frequency penalty.", + "title": "Frequency Penalty" + }, + "presence_penalty": { + "type": "number", + "format": "float", + "description": "The presence penalty.", + "title": "Presence Penalty" + }, + "end_sequences": { + "type": "array", + "items": { + "type": "string" + }, + "description": "The end sequences.", + "title": "End Sequences" + }, + "stop_sequences": { + "type": "array", + "items": { + "type": "string" + }, + "description": "The stop sequences.", + "title": "Stop Sequences" + }, + "return_likelihoods": { + "type": "string", + "description": "The return likelihoods.", + "title": "Return Likelihoods", + "default": "NONE", + "enum": [ + "NONE", + "GENERATION", + "ALL" + ] + }, + "truncate": { + "type": "string", + "description": "The truncate.", + "title": "Truncate", + "enum": [ + "NONE", + "START", + "END" + ] + } + } + } + } + ] + } + }, + "/embed": { + "post": { + "responses": { + "200": { + "description": "default", + "schema": { + "type": "object", + "properties": { + "id": { + "type": "string", + "description": "The identifier.", + "title": "ID" + }, + "texts": { + "type": "array", + "items": { + "type": "string" + }, + "description": "The texts.", + "title": "Texts" + }, + "embeddings": { + "type": "array", + "items": { + "type": "array", + "items": { + "type": "number", + "format": "float" + } + }, + "description": "The embeddings.", + "title": "Embeddings" + }, + "meta": { + "type": "object", + "properties": { + "api_version": { + "type": "object", + "properties": { + "version": { + "type": "string", + "description": "The version.", + "title": "Version" + }, + "is_deprecated": { + "type": "boolean", + "description": "Whether is deprecated.", + "title": "Is Deprecated" + } + }, + "title": "API Version" + } + }, + "title": "Meta" + } + } + } + } + }, + "summary": "Generate text embeddings", + "description": "Returns text embeddings which are lists of floating point numbers that captures semantic information about the text that it represents.", + "operationId": "EmbedPost", + "parameters": [ + { + "name": "body", + "in": "body", + "required": false, + "schema": { + "type": "object", + "properties": { + "texts": { + "type": "array", + "items": { + "type": "string" + }, + "description": "The texts.", + "title": "Texts" + }, + "model": { + "type": "string", + "description": "The model.", + "title": "Model", + "default": "large", + "enum": [ + "large", + "small" + ] + }, + "truncate": { + "type": "string", + "description": "The truncate.", + "title": "Truncate", + "enum": [ + "NONE", + "START", + "END" + ] + } + } + } + } + ] + } + }, + "/classify": { + "post": { + "responses": { + "200": { + "description": "default", + "schema": { + "type": "object", + "properties": { + "id": { + "type": "string", + "description": "The identifier.", + "title": "ID" + }, + "classifications": { + "type": "array", + "items": { + "type": "object", + "properties": { + "id": { + "type": "string", + "description": "The identifier.", + "title": "ID" + }, + "input": { + "type": "string", + "description": "The input.", + "title": "Input" + }, + "prediction": { + "type": "string", + "description": "The prediction.", + "title": "Prediction" + }, + "confidence": { + "type": "number", + "format": "float", + "description": "The confidence.", + "title": "Confidence" + }, + "confidences": { + "type": "array", + "items": { + "type": "object", + "properties": { + "option": { + "type": "string", + "description": "The option.", + "title": "Option" + }, + "confidence": { + "type": "number", + "format": "float", + "description": "The confidence.", + "title": "Confidence" + } + } + }, + "title": "Confidences" + }, + "labels": { + "type": "object", + "properties": { + "Not spam": { + "type": "object", + "properties": { + "confidence": { + "type": "number", + "format": "float", + "description": "The confidence.", + "title": "Confidence" + } + }, + "description": "Not spam" + }, + "Spam": { + "type": "object", + "properties": { + "confidence": { + "type": "number", + "format": "float", + "description": "The confidence.", + "title": "Confidence" + } + }, + "title": "Spam" + } + }, + "title": "labels" + } + } + }, + "title": "Classifications" + }, + "meta": { + "type": "object", + "properties": { + "api_version": { + "type": "object", + "properties": { + "version": { + "type": "string", + "description": "The version.", + "title": "Version" + }, + "is_deprecated": { + "type": "boolean", + "description": "Whether is deprecated.", + "title": "Is Deprecated" + } + }, + "title": "API Version" + } + }, + "title": "Meta" + } + } + } + } + }, + "summary": "Generate classification", + "description": "Creates a prediction about which label fits the specified text inputs best.", + "operationId": "ClassifyPost", + "parameters": [ + { + "name": "body", + "in": "body", + "required": false, + "schema": { + "type": "object", + "properties": { + "inputs": { + "type": "array", + "items": { + "type": "string" + }, + "description": "The inputs.", + "title": "Inputs" + }, + "model": { + "type": "string", + "description": "The model.", + "title": "Model", + "default": "large", + "enum": [ + "large", + "small", + "multilingual-22-12" + ] + }, + "examples": { + "type": "array", + "items": { + "type": "object", + "properties": { + "text": { + "type": "string", + "description": "The text.", + "title": "Text" + }, + "label": { + "type": "string", + "description": "The label.", + "title": "Label" + } + } + }, + "title": "Examples" + }, + "preset": { + "type": "string", + "description": "The preset.", + "title": "Preset" + }, + "truncate": { + "type": "string", + "description": "The truncate.", + "title": "Truncate", + "enum": [ + "NONE", + "START", + "END" + ] + } + } + } + } + ] + } + }, + "/tokenize": { + "post": { + "responses": { + "200": { + "description": "default", + "schema": { + "type": "object", + "properties": { + "tokens": { + "type": "array", + "items": { + "type": "integer", + "format": "int32" + }, + "description": "The tokens.", + "title": "Tokens" + }, + "token_strings": { + "type": "array", + "items": { + "type": "string" + }, + "description": "The token strings.", + "title": "Token Strings" + }, + "meta": { + "type": "object", + "properties": { + "api_version": { + "type": "object", + "properties": { + "version": { + "type": "string", + "description": "The version.", + "title": "Version" + }, + "is_deprecated": { + "type": "boolean", + "description": "Whether is deprecated.", + "title": "Is Deprecated" + } + }, + "title": "API Version" + } + }, + "title": "Meta" + } + } + } + } + }, + "summary": "Generate tokens", + "description": "Splits input text into smaller units called tokens using byte-pair encoding (BPE).", + "operationId": "TokenPost", + "parameters": [ + { + "name": "body", + "in": "body", + "required": false, + "schema": { + "type": "object", + "properties": { + "text": { + "type": "string", + "description": "The text.", + "title": "Text" + } + } + } + } + ] + } + }, + "/detokenize": { + "post": { + "responses": { + "200": { + "description": "default", + "schema": { + "type": "object", + "properties": { + "text": { + "type": "string", + "description": "The text.", + "title": "Text" + }, + "meta": { + "type": "object", + "properties": { + "api_version": { + "type": "object", + "properties": { + "version": { + "type": "string", + "description": "The version.", + "title": "Version" + }, + "is_deprecated": { + "type": "boolean", + "description": "Whether is deprecated.", + "title": "Is Deprecated" + } + }, + "title": "API Version" + } + }, + "title": "Meta" + } + } + } + } + }, + "summary": "Generate detokenized text", + "description": "Converts tokens using byte-pair encoding and returns their text representation.", + "operationId": "DetokenPost", + "parameters": [ + { + "name": "body", + "in": "body", + "required": false, + "schema": { + "type": "object", + "properties": { + "tokens": { + "type": "array", + "items": { + "type": "integer", + "format": "int32" + }, + "description": "The tokens.", + "title": "Tokens" + } + } + } + } + ] + } + }, + "/detect-language": { + "post": { + "responses": { + "200": { + "description": "default", + "schema": { + "type": "object", + "properties": { + "id": { + "type": "string", + "description": "The identifier.", + "title": "ID" + }, + "results": { + "type": "array", + "items": { + "type": "object", + "properties": { + "language_code": { + "type": "string", + "description": "The language code.", + "title": "Language Code" + }, + "language_name": { + "type": "string", + "description": "The language name.", + "title": "Language Name" + } + } + }, + "title": "Results" + }, + "meta": { + "type": "object", + "properties": { + "api_version": { + "type": "object", + "properties": { + "version": { + "type": "string", + "description": "The version.", + "title": "Version" + }, + "is_deprecated": { + "type": "boolean", + "description": "Whether is deprecated.", + "title": "Is Deprecated" + } + }, + "title": "API Version" + } + }, + "title": "Meta" + } + } + } + } + }, + "summary": "Identify language", + "description": "Detects which language each of the provided texts is written in.", + "operationId": "LanguagePost", + "parameters": [ + { + "name": "body", + "in": "body", + "required": false, + "schema": { + "type": "object", + "properties": { + "texts": { + "type": "array", + "items": { + "type": "string" + }, + "description": "The texts.", + "title": "Texts" + } + } + } + } + ] + } + }, + "/summarize": { + "post": { + "responses": { + "200": { + "description": "default", + "schema": { + "type": "object", + "properties": { + "id": { + "type": "string", + "description": "The identifier.", + "title": "ID" + }, + "summary": { + "type": "string", + "description": "The summary.", + "title": "Summary" + }, + "meta": { + "type": "object", + "properties": { + "api_version": { + "type": "object", + "properties": { + "version": { + "type": "string", + "description": "The version.", + "title": "Version" + }, + "is_deprecated": { + "type": "boolean", + "description": "Whether is deprecated.", + "title": "Is Deprecated" + } + }, + "title": "API Version" + } + }, + "title": "Meta" + } + } + } + } + }, + "summary": "Summarize text", + "description": "Generates a summary in English for a given text.", + "operationId": "SummarizePost", + "parameters": [ + { + "name": "body", + "in": "body", + "required": false, + "schema": { + "type": "object", + "properties": { + "length": { + "type": "string", + "description": "The length.", + "title": "Length", + "default": "short", + "enum": [ + "short", + "medium", + "long" + ] + }, + "format": { + "type": "string", + "description": "The format.", + "title": "Format", + "default": "paragraph", + "enum": [ + "paragraph", + "bullet" + ] + }, + "model": { + "type": "string", + "description": "The model.", + "title": "Model", + "default": "summarize-medium", + "enum": [ + "summarize-medium", + "summarize-xlarge" + ] + }, + "extractiveness": { + "type": "string", + "description": "The extractiveness.", + "title": "Extractiveness", + "default": "low", + "enum": [ + "low", + "medium", + "high" + ] + }, + "temperature": { + "type": "number", + "format": "float", + "description": "The temperature.", + "title": "Temperature" + }, + "text": { + "type": "string", + "description": "The text.", + "title": "Text" + } + } + } + } + ] + } + } + }, + "definitions": {}, + "parameters": {}, + "responses": {}, + "securityDefinitions": { + "API Key": { + "type": "apiKey", + "in": "header", + "name": "Authorization" + } + }, + "security": [ + { + "API Key": [] + } + ], + "tags": [], + "x-ms-connector-metadata": [ + { + "propertyName": "Website", + "propertyValue": "https://cohere.ai/" + }, + { + "propertyName": "Privacy policy", + "propertyValue": "https://cohere.ai/privacy" + }, + { + "propertyName": "Categories", + "propertyValue": "AI" + } + ] +} \ No newline at end of file diff --git a/independent-publisher-connectors/Cohere/apiProperties.json b/independent-publisher-connectors/Cohere/apiProperties.json new file mode 100644 index 0000000000..ec44a21b2f --- /dev/null +++ b/independent-publisher-connectors/Cohere/apiProperties.json @@ -0,0 +1,35 @@ +{ + "properties": { + "connectionParameters": { + "api_key": { + "type": "securestring", + "uiDefinition": { + "displayName": "API Key in the form 'Bearer API_Key'", + "description": "The API Key in the form 'Bearer API_Key' for this api", + "tooltip": "Provide your API Key in the form 'Bearer API_Key'", + "constraints": { + "tabIndex": 2, + "clearText": false, + "required": "true" + } + } + } + }, + "iconBrandColor": "#da3b01", + "capabilities": [], + "policyTemplateInstances": [ + { + "templateId": "setheader", + "title": "Add Cohere-Version", + "parameters": { + "x-ms-apimTemplateParameter.name": "Cohere-Version", + "x-ms-apimTemplateParameter.value": "2022-12-06", + "x-ms-apimTemplateParameter.existsAction": "override", + "x-ms-apimTemplate-policySection": "Request" + } + } + ], + "publisher": "Troy Taylor", + "stackOwner": "Cohere" + } +} \ No newline at end of file diff --git a/independent-publisher-connectors/Cohere/readme.md b/independent-publisher-connectors/Cohere/readme.md new file mode 100644 index 0000000000..dc4dbd0124 --- /dev/null +++ b/independent-publisher-connectors/Cohere/readme.md @@ -0,0 +1,29 @@ +# Cohere +Cohere is making natural language processing part of every developer's toolkit. Harness the power of language understanding. Join the developers and businesses who are using Cohere to generate, categorize and organize text at a scale that was previously unimaginable. + +## Publisher: Troy Taylor, Hitachi Solutions + +## Prerequisites +You must signup for an account with [Cohere](https://dashboard.cohere.ai/register). + +## Obtaining Credentials +Once you are logged in to your dashboard, find your API key in the tutorial section. + +## Supported Operations +### Generate text +This action generates realistic text conditioned on a given input. +### Generate text embeddings +Returns text embeddings which are lists of floating point numbers that captures semantic information about the text that it represents. +### Generate classification +Creates a prediction about which label fits the specified text inputs best. +### Generate tokens +Splits input text into smaller units called tokens using byte-pair encoding (BPE). +### Generate detokenized text +Converts tokens using byte-pair encoding and returns their text representation. +### Identify language +Detects which language each of the provided texts is written in. +### Summarize text +Generates a summary in English for a given text. + +## Known Issues and Limitations +There are no known issues at this time. From b8b429cff24deff36b4d8685d9a0493c876267f7 Mon Sep 17 00:00:00 2001 From: Troy Taylor <44444967+troystaylor@users.noreply.github.com> Date: Mon, 13 Mar 2023 13:27:22 -0400 Subject: [PATCH 5/6] Add 200 - OK --- .../Cohere/apiDefinition.swagger.json | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/independent-publisher-connectors/Cohere/apiDefinition.swagger.json b/independent-publisher-connectors/Cohere/apiDefinition.swagger.json index f6972cd9a4..6fd94a70de 100644 --- a/independent-publisher-connectors/Cohere/apiDefinition.swagger.json +++ b/independent-publisher-connectors/Cohere/apiDefinition.swagger.json @@ -26,7 +26,7 @@ "post": { "responses": { "200": { - "description": "default", + "description": "OK", "schema": { "type": "object", "properties": { @@ -189,7 +189,7 @@ "post": { "responses": { "200": { - "description": "default", + "description": "OK", "schema": { "type": "object", "properties": { @@ -293,7 +293,7 @@ "post": { "responses": { "200": { - "description": "default", + "description": "OK", "schema": { "type": "object", "properties": { @@ -482,7 +482,7 @@ "post": { "responses": { "200": { - "description": "default", + "description": "OK", "schema": { "type": "object", "properties": { @@ -555,7 +555,7 @@ "post": { "responses": { "200": { - "description": "default", + "description": "OK", "schema": { "type": "object", "properties": { @@ -620,7 +620,7 @@ "post": { "responses": { "200": { - "description": "default", + "description": "OK", "schema": { "type": "object", "properties": { @@ -703,7 +703,7 @@ "post": { "responses": { "200": { - "description": "default", + "description": "OK", "schema": { "type": "object", "properties": { @@ -844,4 +844,4 @@ "propertyValue": "AI" } ] -} \ No newline at end of file +} From a47b815d65e8642e784ab4bfcc3848cf8da74c62 Mon Sep 17 00:00:00 2001 From: Troy Taylor <44444967+troystaylor@users.noreply.github.com> Date: Fri, 10 May 2024 14:38:15 -0600 Subject: [PATCH 6/6] Add files via upload --- .../Cohere/apiDefinition.swagger.json | 550 +++++++++++++++++- .../Cohere/readme.md | 2 + 2 files changed, 545 insertions(+), 7 deletions(-) diff --git a/independent-publisher-connectors/Cohere/apiDefinition.swagger.json b/independent-publisher-connectors/Cohere/apiDefinition.swagger.json index 6fd94a70de..9d17496a60 100644 --- a/independent-publisher-connectors/Cohere/apiDefinition.swagger.json +++ b/independent-publisher-connectors/Cohere/apiDefinition.swagger.json @@ -3,12 +3,19 @@ "info": { "title": "Cohere", "description": "Cohere is making natural language processing part of every developer's toolkit. Harness the power of language understanding. Join the developers and businesses who are using Cohere to generate, categorize and organize text at a scale that was previously unimaginable.", - "version": "1.0", + "version": "1.1", "contact": { "name": "Troy Taylor", "url": "https://www.hitachisolutions.com", "email": "ttaylor@hitachisolutions.com" - } + }, + "x-ms-keywords": [ + "Cohere", + "AI", + "LLM", + "chat", + "completion" + ] }, "host": "api.cohere.ai", "basePath": "/", @@ -66,6 +73,7 @@ "summary": "Generate text", "description": "This action generates realistic text conditioned on a given input.", "operationId": "GeneratePost", + "deprecated": true, "parameters": [ { "name": "body", @@ -376,7 +384,7 @@ "title": "Spam" } }, - "title": "labels" + "title": "Labels" } } }, @@ -746,6 +754,7 @@ "summary": "Summarize text", "description": "Generates a summary in English for a given text.", "operationId": "SummarizePost", + "deprecated": true, "parameters": [ { "name": "body", @@ -812,13 +821,535 @@ } ] } + }, + "/v1/chat": { + "post": { + "responses": { + "200": { + "description": "default", + "schema": { + "type": "object", + "properties": { + "text": { + "type": "string", + "description": "The text.", + "title": "Text" + }, + "generation_id": { + "type": "string", + "description": "The generation identifier.", + "title": "Generation ID" + }, + "citations": { + "type": "array", + "items": { + "type": "object", + "properties": { + "start": { + "type": "integer", + "format": "int32", + "description": "The start.", + "title": "Start" + }, + "end": { + "type": "integer", + "format": "int32", + "description": "The end.", + "title": "End" + }, + "text": { + "type": "string", + "description": "The text.", + "title": "Text" + }, + "document_ids": { + "type": "array", + "items": { + "type": "string" + }, + "description": "The document identifiers.", + "title": "Document IDs" + } + } + }, + "title": "Citations" + }, + "documents": { + "type": "array", + "items": { + "type": "object", + "properties": { + "id": { + "type": "string", + "description": "The identifier.", + "title": "ID" + }, + "additionalProp": { + "type": "string", + "description": "The additional properties.", + "title": "Additional Properties" + } + } + }, + "title": "Documents" + }, + "is_search_required": { + "type": "boolean", + "description": "Whether is search required.", + "title": "Is Search Required" + }, + "search_queries": { + "type": "array", + "items": { + "type": "object", + "properties": { + "text": { + "type": "string", + "description": "The text.", + "title": "Text" + }, + "generation_id": { + "type": "string", + "description": "The generation identifier.", + "title": "Generation ID" + } + } + }, + "title": "Search Queries" + }, + "search_results": { + "type": "array", + "items": { + "type": "object", + "properties": { + "search_query": { + "type": "object", + "properties": { + "text": { + "type": "string", + "description": "The text.", + "title": "Text" + }, + "generation_id": { + "type": "string", + "description": "The generation identifier.", + "title": "Generation ID" + } + }, + "title": "Search Query" + }, + "connector": { + "type": "object", + "properties": { + "id": { + "type": "string", + "description": "The identifier.", + "title": "ID" + } + }, + "title": "Connector" + }, + "document_ids": { + "type": "array", + "items": { + "type": "string" + }, + "description": "The document identifiers.", + "title": "Document IDs" + }, + "error_message": { + "type": "string", + "description": "The error message.", + "title": "Error Message" + }, + "continue_on_failure": { + "type": "boolean", + "description": "Whether to continue on failure.", + "title": "Continue On Failure" + } + } + }, + "title": "Search Results" + }, + "finish_reason": { + "type": "string", + "description": "The finish reason.", + "title": "Finish Reason" + }, + "tool_calls": { + "type": "array", + "items": { + "type": "object", + "properties": { + "name": { + "type": "string", + "description": "The name.", + "title": "Name" + }, + "parameters": { + "type": "object", + "properties": { + "additionalProp": { + "type": "object", + "properties": {}, + "description": "The addition properties object.", + "title": "Additional Properties" + } + }, + "title": "Parameters" + } + } + }, + "title": "Tool Calls" + }, + "chat_history": { + "type": "array", + "items": { + "type": "object", + "properties": { + "role": { + "type": "string", + "description": "The role.", + "title": "Role" + }, + "message": { + "type": "string", + "description": "The message.", + "title": "Message" + } + } + }, + "title": "Chat History" + }, + "meta": { + "type": "object", + "properties": { + "api_version": { + "type": "object", + "properties": { + "version": { + "type": "string", + "description": "The version.", + "title": "Version" + }, + "is_deprecated": { + "type": "boolean", + "description": "Whether is deprecated.", + "title": "Is Deprecated" + }, + "is_experimental": { + "type": "boolean", + "description": "Whether is experimental.", + "title": "Is Experimental" + } + }, + "title": "API Version" + }, + "billed_units": { + "type": "object", + "properties": { + "input_tokens": { + "type": "integer", + "format": "int32", + "description": "The input tokens.", + "title": "Input Tokens" + }, + "output_tokens": { + "type": "integer", + "format": "int32", + "description": "The output tokens.", + "title": "Output Tokens" + }, + "search_units": { + "type": "integer", + "format": "int32", + "description": "The search units.", + "title": "Search Units" + }, + "classifications": { + "type": "integer", + "format": "int32", + "description": "The classifications.", + "title": "Classifications" + } + }, + "title": "Billed Units" + }, + "tokens": { + "type": "object", + "properties": { + "input_tokens": { + "type": "integer", + "format": "int32", + "description": "The input tokens.", + "title": "Input Tokens" + }, + "output_tokens": { + "type": "integer", + "format": "int32", + "description": "The output tokens.", + "title": "Output Tokens" + } + }, + "title": "Tokens" + }, + "warnings": { + "type": "array", + "items": { + "type": "string" + }, + "description": "The warnings.", + "title": "Warnings" + } + }, + "title": "Meta" + } + } + } + } + }, + "summary": "Get chat", + "description": "Generates a text response to a user message.", + "operationId": "ChatPost", + "x-ms-visibility": "important", + "parameters": [ + { + "name": "body", + "in": "body", + "required": false, + "schema": { + "type": "object", + "properties": { + "message": { + "type": "string", + "description": "Text input for the model to respond to.", + "title": "Message", + "x-ms-visibility": "important" + }, + "model": { + "type": "string", + "description": "The name of a compatible Cohere model or the ID of a fine-tuned model.", + "title": "Model", + "default": "command-r-plus" + }, + "preamble": { + "type": "string", + "description": "When specified, the default Cohere preamble will be replaced with the provided one. Preambles are a part of the prompt used to adjust the model's overall behavior and conversation style, and use the SYSTEM role.", + "title": "Preamble" + }, + "chat_history": { + "type": "array", + "items": { + "type": "object", + "properties": { + "role": { + "type": "string", + "description": "The role.", + "title": "Role", + "enum": [ + "CHATBOT", + "SYSTEM", + "USER" + ] + }, + "message": { + "type": "string", + "description": "The previous message.", + "title": "Message" + } + } + }, + "title": "Chat History" + }, + "conversation_id": { + "type": "string", + "description": "An alternative to chat history. Providing a conversation_id creates or resumes a persisted conversation with the specified ID. The ID can be any non empty string.", + "title": "Conversation ID" + }, + "prompt_truncation": { + "type": "string", + "description": "Dictates how the prompt will be constructed.", + "title": "Prompt Truncation", + "enum": [ + "AUTO", + "AUTO_PRESERVE_ORDER", + "OFF" + ] + }, + "connectors": { + "type": "array", + "items": { + "type": "object", + "properties": { + "id": { + "type": "string", + "description": "The identifier of the connector.", + "title": "ID" + }, + "user_access_token": { + "type": "string", + "description": "When specified, this user access token will be passed to the connector in the Authorization header instead of the Cohere generated one.", + "title": "User Access Token" + }, + "continue_on_failure": { + "type": "boolean", + "description": "When true, the request will continue if this connector returned an error.", + "title": "Continue On Failure" + }, + "options": { + "type": "object", + "properties": {}, + "description": "Provides the connector with different settings at request time.", + "title": "Options" + } + } + }, + "title": "Connectors" + }, + "search_queries_only": { + "type": "boolean", + "description": "When true, the response will only contain a list of generated search queries, but no search will take place, and no reply from the model to the user's message will be generated.", + "title": "Search Queries Only" + }, + "documents": { + "type": "array", + "items": { + "type": "object", + "properties": { + "title": { + "type": "string", + "description": "The document title.", + "title": "Title" + }, + "text": { + "type": "string", + "description": "The document text.", + "title": "Text" + } + } + }, + "title": "Documents" + }, + "citation_quality": { + "type": "string", + "description": "Dictates the approach taken to generating citations as part of the RAG flow by allowing the user to specify whether they want accurate results or fast results.", + "title": "Citation Quality", + "enum": [ + "accurate", + "fast" + ] + }, + "temperature": { + "type": "number", + "format": "float", + "description": "A non-negative float that tunes the degree of randomness in generation. Lower temperatures mean less random generations, and higher temperatures mean more random generations.", + "title": "Temperature" + }, + "max_tokens": { + "type": "integer", + "format": "int32", + "description": "The maximum number of tokens the model will generate as part of the response. Note: Setting a low value may result in incomplete generations.", + "title": "Max Tokens" + }, + "max_input_tokens": { + "type": "integer", + "format": "int32", + "description": "The maximum number of input tokens to send to the model. If not specified, max_input_tokens is the model's context length limit minus a small buffer.", + "title": "Max Input Tokens" + }, + "k": { + "type": "integer", + "format": "int32", + "description": "Ensures only the top k most likely tokens are considered for generation at each step. Defaults to 0, min value of 0, max value of 500.", + "title": "k", + "minimum": 0, + "maximum": 500 + }, + "p": { + "type": "number", + "format": "float", + "description": "Ensures that only the most likely tokens, with total probability mass of p, are considered for generation at each step. If both k and p are enabled, p acts after k. Defaults to 0.75. min value of 0.01, max value of 0.99.", + "title": "p", + "minimum": 0.01, + "maximum": 0.99 + }, + "seed": { + "type": "number", + "format": "float", + "description": "If specified, the backend will make a best effort to sample tokens deterministically, such that repeated requests with the same seed and parameters should return the same result. However, determinism cannot be totally guaranteed.", + "title": "Seed" + }, + "stop_sequences": { + "type": "array", + "items": { + "type": "string" + }, + "description": "A list of up to 5 strings that the model will use to stop generation. If the model generates a string that matches any of the strings in the list, it will stop generating tokens and return the generated text up to that point not including the stop sequence.", + "title": "Stop Sequences" + }, + "frequency_penalty": { + "type": "number", + "format": "float", + "description": "Used to reduce repetitiveness of generated tokens. The higher the value, the stronger a penalty is applied to previously present tokens, proportional to how many times they have already appeared in the prompt or prior generation.", + "title": "Frequency Penalty", + "minimum": 0.0, + "maximum": 1.0 + }, + "presence_penalty": { + "type": "number", + "format": "float", + "description": "Used to reduce repetitiveness of generated tokens. Similar to frequency_penalty, except that this penalty is applied equally to all tokens that have already appeared, regardless of their exact frequencies.", + "title": "Presence Penalty" + }, + "tools": { + "type": "array", + "items": { + "type": "object", + "properties": { + "name": { + "type": "string", + "description": "The name of the tool to be called. Valid names contain only the characters a-z, A-Z, 0-9, _ and must not begin with a digit.", + "title": "Name" + }, + "description": { + "type": "string", + "description": "The description of what the tool does, the model uses the description to choose when and how to call the function.", + "title": "Description" + }, + "parameter_definitions": { + "type": "object", + "properties": {}, + "description": "The input parameters of the tool.", + "title": "Parameter Definitions" + } + } + }, + "title": "Tools" + } + }, + "required": [ + "message" + ] + } + } + ], + "x-ms-openai-data": { + "openai-enabled": true, + "operations": [ + { + "operationId": "ChatPost", + "x-ms-require-user-confirmation": true + } + ] + } + } } }, "definitions": {}, "parameters": {}, "responses": {}, "securityDefinitions": { - "API Key": { + "API Key in the form 'Bearer API_Key'": { "type": "apiKey", "in": "header", "name": "Authorization" @@ -826,7 +1357,7 @@ }, "security": [ { - "API Key": [] + "API Key in the form 'Bearer API_Key'": [] } ], "tags": [], @@ -843,5 +1374,10 @@ "propertyName": "Categories", "propertyValue": "AI" } - ] -} + ], + "x-ms-openai-manifest": { + "humanName": "Cohere", + "modelDescription": "This is a Copilot plugin for the Cohere AI service.", + "contactEmail": "ttaylor@hitachisolutions.com" + } +} \ No newline at end of file diff --git a/independent-publisher-connectors/Cohere/readme.md b/independent-publisher-connectors/Cohere/readme.md index dc4dbd0124..310cb99c3c 100644 --- a/independent-publisher-connectors/Cohere/readme.md +++ b/independent-publisher-connectors/Cohere/readme.md @@ -24,6 +24,8 @@ Converts tokens using byte-pair encoding and returns their text representation. Detects which language each of the provided texts is written in. ### Summarize text Generates a summary in English for a given text. +### Get chat +Generates a text response to a user message. ## Known Issues and Limitations There are no known issues at this time.