1. Attributes & Options
Example be.open API
  • be.open API
    • be.open API
    • Samples
    • Auth
      • Get api auth token
    • Attributes & Options
      • attributes
        • get country options of a product
      • get all available attributes
        GET
      • create or update an attribute
        POST
      • get a single attribute by id
        GET
      • adds or updates an option
        POST
      • list attribute categories
        GET
      • returns options for an attribute type of a service provider
        POST
    • Basket
      • get Basket
    • Price
      • get Price list
    • Categories
      • get product categories
      • Returns the products of a category.
    • Products & Combinations
      • get product configuration
      • get option configuration
      • get product attributes
      • get product independent attributes
      • Returns the products.
      • adds or updates a product with attributes, options and combinations.
      • Returns the single product.
      • adds or updates attributes, options and combinations of a product. Used to import combinations in parts
      • delete combinations.
      • get country attribute with options
    • Serviceprovider
      • change attribute settings just for this service provider
      • change option settings just for this service provider
      • change attribute category setting just for this service provider
      • list orders for a service provider
      • get an order for a service provider
      • update order status from service provider
    • Order
      • create an order
      • get order
    • change attribute category setting just for this service provider
      PATCH
    • change attribute category setting just for this service provider
      PATCH
    • Schemas
      • Schemas
        • Attribute
        • AttributeCategory
        • CategoryModel
        • Product
        • BasicOrder
        • Order
        • Option
        • ProductMetaInformation
        • Client
        • OrderDetail
        • OrderCustomField
        • OrderFile
        • OrderUpload
        • File
        • PartialDelivery
        • OrderDetailFile
        • ProductCombination
        • Address
        • OrderDetailPrice
        • OrderDetailCombination
        • Address2
        • PriceConfiguration
        • Currency
        • ConfigurationOption
        • Price
        • ConfigurationOptionSize
      • Improved Schemas
        • ExampleAttributesCollection
        • Attribute
        • AttributeMetaData
        • Category
      • Responses
      • Custom Schemas
        • UpdateServiceproviderOrderResponse
      • AttributeOption
      • CreateProduct
      • QuantityShipping
      • QuantityDelivery
      • DeleteQuantityShipping
      • placedOrder
      • DeleteQuantityDelivery
      • Authentication
      • AuthenticationResponse
      • CreateAttribute
      • CreateOption
      • CreateProductCombination
      • DeleteProductCombination
      • ProductTypeData
      • DependableAttribute
      • ProductVariant
      • DeleteProductVariant
      • ServiceproviderOrderDetail
      • DependableOption
      • ProductQuantity
      • ProductAttribute
      • DeleteProductQuantity
      • OrderDetailPage
      • OptionOfAttribute
      • ProductResponse
      • LooseLeafData
      • AttributeResponse
      • OrderResponse
      • OrderDetailResponse
      • OrderAttributeOption
      • BasketPrice
      • OrderAddressResponse
      • CreateOrderAddress
      • CreateOrder
      • PatchServiceProviderOrder
      • JsonApi
      • PaginationMeta
      • PaginationLinks
      • AttributesListResponse
      • AttributeSingleResponse
      • OptionSingleResponse
      • AttributeResource
      • OptionIdentifier
      • AttributeCategoryEmbedded
      • AttributeCategoryResource
      • OptionResource
  • Druckshop API
    • Cart
      • getByJobNumber
    • Tracking
      • getByJobNumber
      • addTrackingId
    • Order
      • getOrder
      • getOrders
      • getOrderByReference
      • getOrderCart
    • FreeOrder
      • addFreeOrder
    • Schemas
      • FreeOrder
      • FreeOrderResponse
      • ApiAddress
      • FreeOrderPrice
      • FreeOrderCart
      • FreeOrderArticle
      • FreeOrderDataKeyValuePrice
  • be.print Dashboard API
    • PlacedOrder
      • Store a newly created placedOrder
      • Update an existing placedOrder
    • PlacedOrderCart
      • Store a newly created placedOrderCart
      • Update an existing placedOrderCart
    • Sso
      • sso.getTokenCheck
      • sso.setUserMapping
    • ValidateCustomerApi
      • validateCustomerApi.whoAmI
      • validateCustomerApi.postExternalClient
    • Dashboard API (MOVE TO ANOTHER PROJECT)!
      • Customer
        • whoAmI
        • addExternalClient
      • Orders
        • create order
        • update order
        • update order cart
    • Schemas
      • Schemas
        • AddExternalClientRequest
        • PlacedOrderCartRequest
        • PlacedOrderRequest
        • SsoExternalLinkRequest
        • SsoExternalUserMapping
      • Response
        • AuthenticationException
        • ValidationException
        • AuthorizationException
        • ModelNotFoundException
      • placedOrder
  1. Attributes & Options

create or update an attribute

POST
/api/attributes
Creates a new attribute or updates an existing one for a service provider. Authentication: requires ROLE_INTERNAL_ADMIN. Lookup semantic: the server tries to find an existing attribute by (service_provider_id, key); if found, the attribute is updated (name, sort, category, attribute_style, attribute_type, description, attribute category, translation in the default locale). If not found, a new attribute is created with field_type=single and — when attribute_type is omitted — defaults to other. On update, an omitted attribute_type does not overwrite the existing value. Required fields: service_provider_id, key, name, category_id. Optional: description, sort (default 0), category (default none), attribute_style (server default applies if missing), attribute_type.

Request

Authorization
JWT Bearer
Add the parameter
Authorization
to Headers
Example:
Authorization: ********************
or
Header Params

Body Params application/jsonRequired

Example
{
    "service_provider_id": "11111111-2222-3333-4444-555555555555",
    "key": "color",
    "name": "Farbe",
    "description": null,
    "sort": 1,
    "category": "none",
    "category_id": "5117a596-fd4f-4fba-a27e-5affde564b2c",
    "attribute_style": "normal",
    "attribute_type": "other"
}

Responses

🟢200returns the attribute
application/json
Returns the created attribute.
Bodyapplication/json

Example
{
    "jsonapi": {
        "version": "1.0"
    },
    "data": {
        "type": "attributes",
        "id": "0e2e958e-ea2c-45e6-b1f0-b0d383b5cecb",
        "attributes": {
            "name": "Farbe",
            "original_name": "Farbe",
            "sort": 1,
            "description": null,
            "key": "color",
            "category": "none",
            "attribute_category": {
                "type": "attribute_categories",
                "id": "5117a596-fd4f-4fba-a27e-5affde564b2c",
                "attributes": {
                    "name": "none",
                    "sort": 0,
                    "key": "none"
                }
            },
            "sort_type": 1,
            "field_type": "single",
            "attribute_style": "normal",
            "attribute_type": "other",
            "base_url": ""
        },
        "relationships": {
            "options": {
                "data": [
                    {
                        "type": "options",
                        "id": "7fff7f85-1869-43d3-a831-8ac14d77aea5"
                    },
                    {
                        "type": "options",
                        "id": "17d3f17e-67c3-4a85-97aa-db614caba671"
                    }
                ]
            }
        }
    },
    "included": [
        {
            "type": "options",
            "id": "7fff7f85-1869-43d3-a831-8ac14d77aea5",
            "attributes": {
                "name": "Blau",
                "original_name": "Blau",
                "key": "blue",
                "description": null,
                "sort": 0,
                "icon_name": "",
                "is_highlight": false,
                "meta": []
            }
        },
        {
            "type": "options",
            "id": "17d3f17e-67c3-4a85-97aa-db614caba671",
            "attributes": {
                "name": "Rot",
                "original_name": "Rot",
                "key": "red",
                "description": null,
                "sort": 50,
                "icon_name": "main_icon",
                "is_highlight": true,
                "meta": []
            }
        }
    ]
}
🟠401Unauthorized request
🟠404NotFound
Modified at 2026-05-29 10:44:16
Previous
get all available attributes
Next
get a single attribute by id
Built with