Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 3 Current »

General Information


Service

API

Method

Data Models

Workflow

marketplace

/recipe

GET

N/A

N/A

Description

Get catalog recipe by id

Input


Type: application/json

Input

Source

Required

Type

Description

id

query

Yes

String

version

query

No

number

specify the version number

Output


Response

SOAJS has a unified response. Check out this link to understand more the schema of SOAJS response 

Valid Response

 SAMPLE
{
  "result": true,
  "data": {
    "_id": "5ef5a98e707a10af2f5d84c8",
    "description": "Deploy Node.js service",
    "name": "Controller",
    "recipe": {
      "deployOptions": {
        "image": {
          "prefix": "soajsorg",
          "name": "gateway",
          "tag": "latest",
          "pullPolicy": "Always",
          "repositoryType": "public",
          "override": true,
          "shell": "shell/bin/bash",
          "binary": true
        },
        "sourceCode": {},
        "readinessProbe": {
          "exec": {
            "command": [
              "ls"
            ]
          },
          "initialDelaySeconds": 5,
          "timeoutSeconds": 2,
          "periodSeconds": 5,
          "successThreshold": 1,
          "failureThreshold": 4
        },
        "livenessProbe": null,
        "ports": [
          {
            "name": "http",
            "target": 80,
            "isPublished": true,
            "published": 30080
          }
        ],
        "voluming": [
          {
            "docker": {},
            "kubernetes": {
              "volume": {
                "name": "soajsprofile",
                "secret": {
                  "secretName": "soajsprofile"
                }
              },
              "volumeMount": {
                "mountPath": "/opt/soajs/profile/",
                "name": "soajsprofile"
              }
            }
          }
        ],
        "restartPolicy": {
          "condition": "any",
          "maxAttempts": 5
        },
        "container": {
          "network": "soajsnet",
          "workingDir": ""
        },
        "labels": {
          "ragheb": "ragheb"
        },
        "execCommands": {
          "list": "ls -l"
        }
      },
      "buildOptions": {
        "env": {
          "SOAJS_ENV": {
            "type": "computed",
            "value": "$SOAJS_ENV"
          },
          "SOAJS_DEPLOY_HA": {
            "type": "computed",
            "value": "$SOAJS_DEPLOY_HA"
          },
          "SOAJS_PROFILE": {
            "type": "static",
            "value": "/opt/soajs/profile/soajsprofile"
          },
          "SOAJS_MONGO_CON_KEEPALIVE": {
            "type": "static",
            "value": "true"
          },
          "SOAJS_EXTKEY": {
            "type": "computed",
            "value": "$SOAJS_EXTKEY"
          }
        },
        "cmd": {
          "deploy": {
            "command": [
              "bash"
            ],
            "args": [
              "-c",
              "node ."
            ]
          }
        }
      }
    },
    "restriction": {
      "deployment": [
        "container"
      ]
    },
    "subtype": "nodejs",
    "ts": 1595250459348,
    "type": "service",
    "v": 1
  }
}

Invalid Response

 SAMPLE
{
    "result":false,
    "errors":{
        "codes":[602],
        "details":[
            {
                "code":602,
                "message":"Model error: + %model_error%"
            }
        ]
    }
}

Response schema

Follow this link to check out the response JSON Schema

SOAJS Error Codes


Code

Description

400

Business logic required data are missing

602

Model error: + %model_error%

  • No labels

0 Comments

You are not logged in. Any changes you make will be marked as anonymous. You may want to Log In if you already have an account.