---
title: "Create a new scoring function at environment level"
method: POST
path: "/scoring/functions"
tags: ["Scoring", "Functions"]
---

# Create a new scoring function at environment level

`POST /scoring/functions`

## Request body

- ImportScoringFunction — The scoring scoring function to import
  - `name` string — The name of ruleset
  - `payload` string — The scoring function payload

## Response `201`

Scoring functions created

## Other responses

- `default` — Generic error response

---

[API](https://skmtc.net/gravitee-io/apis/gravitee-io-apim-management-api-environments.md) · [All operations](https://skmtc.net/gravitee-io/apis/gravitee-io-apim-management-api-environments/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/gravitee-io/gravitee-io-apim-management-api-environments/versions/a2bffc8c2e17/schema)
