Skip to content

Instantly share code, notes, and snippets.

@knolleary
Created June 26, 2023 15:53
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save knolleary/76d6c16eae18144685c2fd57bc287a9a to your computer and use it in GitHub Desktop.
Save knolleary/76d6c16eae18144685c2fd57bc287a9a to your computer and use it in GitHub Desktop.
{
"swagger": "2.0",
"info": {
"title": "FlowForge Platform API",
"description": "API documentation for interacting with the FlowForge platform",
"version": "1.8.0-git"
},
"definitions": {
"def-0": {
"type": "object",
"properties": {
"status": {
"type": "string"
}
},
"title": "APIStatus"
},
"def-1": {
"type": "object",
"properties": {
"code": {
"type": "string"
},
"error": {
"type": "string"
}
},
"title": "APIError"
}
},
"paths": {
"/account/authorize": {
"get": {
"tags": [
"Authentication"
],
"parameters": [
{
"type": "string",
"required": true,
"in": "query",
"name": "response_type"
},
{
"type": "string",
"required": true,
"in": "query",
"name": "scope"
},
{
"type": "string",
"required": true,
"in": "query",
"name": "code_challenge"
},
{
"type": "string",
"required": true,
"in": "query",
"name": "code_challenge_method"
}
],
"responses": {
"200": {
"description": "Default Response"
}
}
}
},
"/account/complete/{code}": {
"get": {
"tags": [
"Authentication"
],
"responses": {
"200": {
"description": "Default Response"
}
}
}
},
"/account/reject/{code}": {
"get": {
"tags": [
"Authentication"
],
"responses": {
"200": {
"description": "Default Response"
}
}
}
},
"/account/token": {
"post": {
"tags": [
"Authentication"
],
"parameters": [
{
"name": "body",
"in": "body",
"schema": {
"type": "object",
"properties": {
"grant_type": {
"type": "string"
},
"code": {
"type": "string"
},
"code_verifier": {
"type": "string"
},
"client_id": {
"type": "string"
},
"client_secret": {
"type": "string"
},
"redirect_uri": {
"type": "string"
},
"refresh_token": {
"type": "string"
}
},
"required": [
"grant_type"
]
}
}
],
"responses": {
"200": {
"description": "Default Response"
}
}
}
},
"/account/check/{ownerType}/{ownerId}": {
"get": {
"tags": [
"Authentication"
],
"responses": {
"200": {
"description": "Default Response"
}
}
}
},
"/account/login": {
"post": {
"summary": "Log in to the platform",
"description": "Log in to the platform. If SSO is enabled for this user, the response will prompt the user to retry via the SSO login mechanism.",
"tags": [
"Authentication"
],
"parameters": [
{
"name": "body",
"in": "body",
"schema": {
"type": "object",
"required": [
"username"
],
"properties": {
"username": {
"type": "string"
},
"password": {
"type": "string"
}
}
}
}
],
"responses": {
"200": {
"description": "Default Response"
}
}
}
},
"/account/logout": {
"post": {
"tags": [
"Authentication"
],
"responses": {
"200": {
"description": "Default Response"
}
}
}
},
"/account/register": {
"post": {
"tags": [
"Authentication"
],
"parameters": [
{
"name": "body",
"in": "body",
"schema": {
"type": "object",
"required": [
"username",
"password",
"name",
"email"
],
"properties": {
"username": {
"type": "string"
},
"password": {
"type": "string"
},
"name": {
"type": "string"
},
"email": {
"type": "string"
},
"code": {
"type": "string"
}
}
}
}
],
"responses": {
"200": {
"description": "Default Response"
}
}
}
},
"/account/verify/{token}": {
"post": {
"tags": [
"Authentication"
],
"responses": {
"200": {
"description": "Default Response"
}
}
}
},
"/account/verify": {
"post": {
"tags": [
"Authentication"
],
"responses": {
"200": {
"description": "Default Response"
}
}
}
},
"/account/email_change/{token}": {
"post": {
"tags": [
"Authentication"
],
"responses": {
"200": {
"description": "Default Response"
}
}
}
},
"/account/forgot_password": {
"post": {
"tags": [
"Authentication"
],
"parameters": [
{
"name": "body",
"in": "body",
"schema": {
"type": "object",
"required": [
"email"
],
"properties": {
"email": {
"type": "string"
}
}
}
}
],
"responses": {
"200": {
"description": "Default Response"
}
}
}
},
"/account/reset_password/{token}": {
"post": {
"tags": [
"Authentication"
],
"parameters": [
{
"name": "body",
"in": "body",
"schema": {
"type": "object",
"required": [
"password"
],
"properties": {
"password": {
"type": "string"
}
}
}
}
],
"responses": {
"200": {
"description": "Default Response"
}
}
}
},
"/api/v1/user/": {
"get": {
"summary": "Get the current user profile",
"tags": [
"User"
],
"responses": {
"200": {
"description": "Default Response",
"schema": {
"type": "object",
"properties": {
"id": {
"type": "string"
},
"username": {
"type": "string"
},
"name": {
"type": "string"
},
"email": {
"type": "string"
},
"avatar": {
"type": "string"
},
"admin": {
"type": "boolean"
},
"createdAt": {
"type": "string"
},
"suspended": {
"type": "boolean"
},
"email_verified": {
"type": "boolean"
},
"defaultTeam": {
"type": "string"
},
"sso_enabled": {
"type": "boolean"
}
}
}
},
"400": {
"description": "Default Response",
"schema": {
"$ref": "#/definitions/def-1"
}
}
}
}
},
"/api/v1/user/change_password": {
"put": {
"summary": "Change a users password",
"tags": [
"User"
],
"parameters": [
{
"name": "body",
"in": "body",
"schema": {
"type": "object",
"required": [
"old_password",
"password"
],
"properties": {
"old_password": {
"type": "string"
},
"password": {
"type": "string"
}
}
}
}
],
"responses": {
"200": {
"description": "Default Response",
"schema": {
"$ref": "#/definitions/def-0"
}
},
"400": {
"description": "Default Response",
"schema": {
"$ref": "#/definitions/def-1"
}
}
}
}
}
},
"externalDocs": {
"url": "https://flowforge.com/docs",
"description": "Find more info here"
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment