Create Project

Creates a new optimization project under a specific model in globalMOO.

Endpoint

POST /models/{model_id}/projects

Path Parameters

Parameter
Type
Required
Description

model_id

integer

Yes

ID of the model

Request Parameters

Parameter
Type
Required
Description

name

string

Yes

Project name (≥4 characters)

inputCount

integer

Yes

Number of input variables for optimization (must be > 0)

minimums

array[float]

Yes

Minimum values for each input variable (length must match inputCount)

maximums

array[float]

Yes

Maximum values for each input variable (length must match inputCount, each value must be > corresponding minimum)

inputTypes

array[string]

Yes

Type of each input variable (length must match inputCount)

categories

array[string]

No

Categories for CATEGORICAL inputs (required when type is CATEGORICAL)

Input Types

Available input types are:

  • CONTINUOUS - Floating point numbers within defined min/max range

  • INTEGER - Whole numbers within defined min/max range

  • CATEGORICAL - Selection from predefined category list

  • LOGICAL - Boolean values represented as 0 or 1

Request Format

Response Fields

Field
Type
Description

id

integer

Unique identifier for the project

model_id

integer

ID of the parent model

input_count

integer

Number of input variables

minimums

array[float]

Minimum values for each input

maximums

array[float]

Maximum values for each input

input_types

array[string]

Types for each input (see Input Types)

categories

array[string]

Categories for CATEGORICAL inputs

created_at

string

ISO 8601 timestamp with millisecond precision

updated_at

string

ISO 8601 timestamp with millisecond precision

Response Format

Examples

Response Example

Error Responses

Status Code
Description

400

Invalid request - Missing required fields, invalid format, or validation errors

401

Unauthorized - Invalid API key

404

Model not found

429

Too many requests - Rate limit exceeded

500

Internal server error

Validation Rules

  • Model ID must be a positive integer

  • Project name must be at least 4 characters

  • inputCount must be a positive integer

  • Array lengths must all match inputCount:

    • minimums array

    • maximums array

    • inputTypes array

  • For each input:

    • minimum value must be less than maximum value

    • INTEGER type requires integer min/max values

    • CATEGORICAL type requires corresponding category string in categories array

    • LOGICAL type ignores min/max values

  • CONTINUOUS and INTEGER minimums/maximums must be valid numbers

  • Model must exist and be active

Last updated