---
id: link-specification-create
title: "Create a link specification"
description: "Create a link specification"
sidebar_label: "Create a link specification"
hide_title: true
hide_table_of_contents: true
api: eJztW3tvG8cR/yqLRYE47ZGSVae1CRQFbTGuYkUURMkOyrDM8m5Ibny3e97dk8wQ/O7FzN6TPImyYSB1w79EDfcxz988FlxznYIRTmp1FvEej6V6P7UphHIuQyL3QgPCAQ+4EwvLe2N+LtV7Pgl4BDY0MsVFvMdf0TImGB7BGkfwgBv4kIF1L3W04r01/SsNRLznTAYBD7VyoBx+JdI0zvcd/Wrx6DW34RISgZ/cKgXe43r2K4SOBzw1yL+TYPFbJRKorbLOSLXgAU+kOge1cEveexpwpekiUFnCe2OVxfFksy3NhUiA6TlzS2CgnHSrLvsxs47NUESlVQeS1K2Yv4IJFTGlHYMPmYiZ0wxP5XiqTEBZqRXx56SLkbFRXTvstFiDOn5Ivk3ARRRJ3CTiy4bkD+ulUne5cqZ1DEIhj7cizhqnCGPEigdcOkjsrj43m3sZmYvYQlC7b1x9ntA2a+VCiVkMU6fx6AjmIosd3qpWlQJK0+VWyr+NaqqyoU5h1w9z3YJl0pvPgrmVIbBQKLIecQARWkmoVW7dgGkVr1hlroBp42l0j+2ipoRzRs4yBw1r9gvqPvs94MelGtY7rth0ltwnS06YP7PunbcilhH7YTS8YCN/YZuRH3P1W9qEKtOhFA4idifdsslAfjNdSgCwEFJZx1Kjb2UEUc4gR+vX/SInl5xNSmWtMPhsLUTb1jYZ7cexvoOIFScwRUfs89PmIUPSCDOQGrDoFhTYNVWT8CIXiGK+ppmctU3ALcQQOm2aIZ8T9/qITFJtXGus1mxFAmxoL2rZ7Ee9RHws/zs+DrYCbxPwUDhYaLP6AkfZbDb9Ysc9gHpCrYZz3ht/2g2boFyvsmQGhtcoFS7WFiGW7+aIN7DqkNWZbvEcDAKhQsSfwh02Ac8sTHP5piJ0RWIoRfbpsMXuD0LcbspldqmzOGIic3oBClM8MOks89k8YFka0V/04ghiwMj1/LC50Ukzxm2JMqeeUYvoibyyuT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A==
sidebar_class_name: "post api-method"
info_path: docs/api/nullplatform-api
custom_edit_url: null
---

import MethodEndpoint from "@theme/ApiExplorer/MethodEndpoint";
import ParamsDetails from "@theme/ParamsDetails";
import RequestSchema from "@theme/RequestSchema";
import StatusCodes from "@theme/StatusCodes";
import OperationTabs from "@theme/OperationTabs";
import TabItem from "@theme/TabItem";
import Heading from "@theme/Heading";

<Heading
  as={"h1"}
  className={"openapi__heading"}
  children={"Create a link specification"}
>
</Heading>

<MethodEndpoint
  method={"post"}
  path={"/link_specification"}
  context={"endpoint"}
>
  
</MethodEndpoint>



Create a link specification

<Heading
  id={"request"}
  as={"h2"}
  className={"openapi-tabs__heading"}
  children={"Request"}
>
</Heading>

<ParamsDetails
  parameters={undefined}
>
  
</ParamsDetails>

<RequestSchema
  title={"Body"}
  body={{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"not":{"enum":[null]},"description":"Name of the entity. Must be a non-empty string and not equal to null"},"dimensions":{"title":"Specification Dimension","type":"object","properties":{},"additionalProperties":{"type":"object","properties":{"required":{"type":"boolean"},"values":{"type":"array","items":{"type":"string"}}},"additionalProperties":false,"required":["required"]}},"assignable_to":{"default":"any","type":"string","enum":["any","dimension","scope"],"description":"Specifies if the service can be assigned to any entity, only dimensions, or only scopes."},"attributes":{"title":"Attribute","type":"object","properties":{"schema":{"type":"object","default":{},"description":"Specification of the attribute schema. Must be a valid JSON Schema"},"values":{"type":"object","default":{},"description":"Values associated with the attribute. Must validate against provided schema"}},"required":["schema","values"],"propertyNames":{"enum":["schema","values"],"description":"Allowed property names"},"additionalProperties":false,"description":"Object representing an attribute with a schema and associated values"},"selectors":{"title":"Selector","type":"object","properties":{"imported":{"type":"boolean","default":false},"provider":{"type":"string","minLength":1,"maxLength":100,"default":"any"},"category":{"type":"string","minLength":1,"maxLength":100,"default":"any"},"sub_category":{"type":"string","minLength":1,"maxLength":100,"default":"any"}},"additionalProperties":{"anyOf":[{"type":"string","minLength":1,"maxLength":100},{"type":"number"},{"type":"boolean"},{"type":"null"}]},"description":"Key-value object representing instance selectors"},"use_default_actions":{"default":true,"type":"boolean","description":"Specifies if the link specification should autogenerate its create, update, and delete actions from the attributes schema. Defaults to true for new specifications. An explicitly sent value always wins"},"use_default_naming":{"default":true,"type":"boolean","description":"When true, the link name is optional and generated by nullplatform or taken from the schema's `name` property. When false, a caller-provided name is required. Defaults to true for new specifications"},"external":{"title":"External","type":"object","nullable":true,"properties":{"action":{"type":"string","minLength":1,"description":"Action to send to the agent for resolving external data"},"output_schema":{"type":"object","description":"JSON Schema to validate the agent response against"}},"additionalProperties":false,"required":["action","output_schema"],"description":"Configuration for resolving external context data via the nullplatform agent"},"visible_to":{"title":"Visibility","type":"array","description":"Array representing visibility settings for the entity. Specifies what/who can see this entity","items":{"title":"NRN","type":"string","pattern":"^organization=[0-9*]+(:account=[0-9*]+)?(:namespace=[0-9*]+)?(:application=[0-9*]+)?(:scope=[0-9*]+)?$","description":"Nullplatform Resource Name (NRN) representing a hierarchical identifier for nullplatform resources"}},"unique":{"type":"boolean","description":"Indicates whether the service can be linked only once by an instance of this link specification"},"specification_id":{"title":"Id","type":"string","format":"uuid","description":"Unique identifier for the entity represented as a UUID"},"scopes":{"title":"Specification Scope","type":"object","properties":{"provider":{"type":"object","properties":{"values":{"type":"array","items":{"oneOf":[{"type":"string","enum":["AWS:SERVERLESS:LAMBDA","AWS:WEB_POOL:EC2INSTANCES","AWS:WEB_POOL:EKS","AZURE:WEB_POOL:AKS","GOOGLE:WEB_POOL:GKE","OCI:WEB_POOL:OKE"]},{"type":"string","format":"uuid","description":"UUID of a scope specification"}]},"minItems":1}},"additionalProperties":false,"required":["values"]}},"additionalProperties":false},"external_resolution":{"type":"object","description":"Status of the external context resolution when the link specification was read","properties":{"status":{"type":"string","description":"Resolution outcome. One of: success, no_channel, agent_error, timeout, auth_error, service_unavailable, invalid_response"},"error":{"type":"string","description":"Human-readable error detail when status is not success"},"notification_id":{"type":"string","description":"ID of the notification sent to the agent. Present on error statuses to facilitate debugging"}},"required":["status"]}},"description":"Object representing link specifications","additionalProperties":false,"title":"LinkSpecification","example":{"name":"my-link-specification","specification_id":"eb0b880a-b7e4-42b8-98f9-40c262c59a23","unique":true,"dimensions":{"environment":{"required":true,"values":["production","staging"]}},"scopes":{"provider":{"values":["AWS:SERVERLESS:LAMBDA","AWS:WEB_POOL:EC2INSTANCES","uuid-of-a-specific-scope-specification"]}},"assignable_to":"any","attributes":{"schema":{"type":"object","properties":{"my_string_property":{"type":"string"},"my_number_property":{"type":"number","default":0}},"required":["my_string_property"]},"values":{}}},"required":["name","unique","specification_id"]}}},"description":"Object representing link specifications"}}
>
  
</RequestSchema>

<StatusCodes
  id={undefined}
  label={undefined}
  responses={{"2XX":{"description":"Object representing link specifications","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"title":"Id","type":"string","format":"uuid","description":"Unique identifier for the entity represented as a UUID"},"name":{"type":"string","minLength":1,"not":{"enum":[null]},"description":"Name of the entity. Must be a non-empty string and not equal to null"},"slug":{"type":"string","minLength":1,"not":{"enum":[null]},"description":"Slug of the specification. Automatically generated from \"name\""},"created_at":{"type":"string","format":"date"},"updated_at":{"type":"string","format":"date"},"visible_to":{"title":"Visibility","type":"array","description":"Array representing visibility settings for the entity. Specifies what/who can see this entity","items":{"title":"NRN","type":"string","pattern":"^organization=[0-9*]+(:account=[0-9*]+)?(:namespace=[0-9*]+)?(:application=[0-9*]+)?(:scope=[0-9*]+)?$","description":"Nullplatform Resource Name (NRN) representing a hierarchical identifier for nullplatform resources"}},"unique":{"type":"boolean","description":"Indicates whether the service can be linked only once by an instance of this link specification"},"specification_id":{"title":"Id","type":"string","format":"uuid","description":"Unique identifier for the entity represented as a UUID"},"dimensions":{"title":"Specification Dimension","type":"object","properties":{},"additionalProperties":{"type":"object","properties":{"required":{"type":"boolean"},"values":{"type":"array","items":{"type":"string"}}},"additionalProperties":false,"required":["required"]}},"scopes":{"title":"Specification Scope","type":"object","properties":{"provider":{"type":"object","properties":{"values":{"type":"array","items":{"oneOf":[{"type":"string","enum":["AWS:SERVERLESS:LAMBDA","AWS:WEB_POOL:EC2INSTANCES","AWS:WEB_POOL:EKS","AZURE:WEB_POOL:AKS","GOOGLE:WEB_POOL:GKE","OCI:WEB_POOL:OKE"]},{"type":"string","format":"uuid","description":"UUID of a scope specification"}]},"minItems":1}},"additionalProperties":false,"required":["values"]}},"additionalProperties":false},"assignable_to":{"type":"string","enum":["any","dimension","scope"],"description":"Specifies if the service can be assigned to any entity, only dimensions, or only scopes."},"attributes":{"title":"Attribute","type":"object","properties":{"schema":{"type":"object","default":{},"description":"Specification of the attribute schema. Must be a valid JSON Schema"},"values":{"type":"object","default":{},"description":"Values associated with the attribute. Must validate against provided schema"}},"required":["schema","values"],"propertyNames":{"enum":["schema","values"],"description":"Allowed property names"},"additionalProperties":false,"description":"Object representing an attribute with a schema and associated values"},"selectors":{"title":"Selector","type":"object","properties":{"imported":{"type":"boolean","default":false},"provider":{"type":"string","minLength":1,"maxLength":100,"default":"any"},"category":{"type":"string","minLength":1,"maxLength":100,"default":"any"},"sub_category":{"type":"string","minLength":1,"maxLength":100,"default":"any"}},"additionalProperties":{"anyOf":[{"type":"string","minLength":1,"maxLength":100},{"type":"number"},{"type":"boolean"},{"type":"null"}]},"description":"Key-value object representing instance selectors"},"use_default_actions":{"type":"boolean","description":"Specifies if the link specification should autogenerate its create, update, and delete actions from the attributes schema. Defaults to true for new specifications"},"use_default_naming":{"type":"boolean","description":"When true, the link name is optional and generated by nullplatform or taken from the schema's `name` property. When false, a caller-provided name is required. Defaults to true for new specifications"},"external":{"title":"External","type":"object","nullable":true,"properties":{"action":{"type":"string","minLength":1,"description":"Action to send to the agent for resolving external data"},"output_schema":{"type":"object","description":"JSON Schema to validate the agent response against"}},"additionalProperties":false,"required":["action","output_schema"],"description":"Configuration for resolving external context data via the nullplatform agent"},"external_resolution":{"type":"object","description":"Status of the external context resolution when the link specification was read","properties":{"status":{"type":"string","description":"Resolution outcome. One of: success, no_channel, agent_error, timeout, auth_error, service_unavailable, invalid_response"},"error":{"type":"string","description":"Human-readable error detail when status is not success"},"notification_id":{"type":"string","description":"ID of the notification sent to the agent. Present on error statuses to facilitate debugging"}},"required":["status"]}},"description":"Object representing link specifications","additionalProperties":false,"title":"LinkSpecification","example":{"name":"my-link-specification","specification_id":"eb0b880a-b7e4-42b8-98f9-40c262c59a23","unique":true,"dimensions":{"environment":{"required":true,"values":["production","staging"]}},"scopes":{"provider":{"values":["AWS:SERVERLESS:LAMBDA","AWS:WEB_POOL:EC2INSTANCES","uuid-of-a-specific-scope-specification"]}},"assignable_to":"any","attributes":{"schema":{"type":"object","properties":{"my_string_property":{"type":"string"},"my_number_property":{"type":"number","default":0}},"required":["my_string_property"]},"values":{}}}}}}},"4XX":{"description":"Format for representing errors during API interactions","content":{"application/json":{"schema":{"title":"Error","type":"object","properties":{"statusCode":{"type":"number","description":"HTTP status code indicating the error"},"code":{"type":"string","description":"Unique error code for reference and categorization"},"error":{"type":"string","description":"Short, human-readable error type or category"},"message":{"type":"string","description":"Detailed error message providing additional context"}},"description":"Format for representing errors during API interactions","required":["statusCode","error","message"]}}}},"5XX":{"description":"Format for representing errors during API interactions","content":{"application/json":{"schema":{"title":"Error","type":"object","properties":{"statusCode":{"type":"number","description":"HTTP status code indicating the error"},"code":{"type":"string","description":"Unique error code for reference and categorization"},"error":{"type":"string","description":"Short, human-readable error type or category"},"message":{"type":"string","description":"Detailed error message providing additional context"}},"description":"Format for representing errors during API interactions","required":["statusCode","error","message"]}}}}}}
>
  
</StatusCodes>


      