Get Marketing Texts -------------------- Retrieve marketing texts for a cost rate. The response returns all stored \ text types per locale under a ``data`` key, keyed by locale with the text \ types described in :ref:`marketing-text-structure`. Results can optionally \ be filtered to specific locales by passing one or more ``locales[]`` query \ parameters. By default the request returns the cost rate's default marketing texts. \ To retrieve the texts authored against a single schedule entry, pass its \ UUID as ``rate_cost_schedule_uuid`` (see \ :ref:`marketing-text-schedule-scope`). **Request** - Method: ``GET`` - Path: ``/api/dynamic_pricing/cost_rate_marketing_text`` **Query parameters** .. list-table:: :widths: 25 15 60 :header-rows: 1 * - Name - Type - Description * - cost_rate_uuid - string - UUID of the cost rate to retrieve marketing texts for. **Required.** * - locales[] - string - Optional. One or more locale codes to filter by. Repeat the parameter \ for multiple locales (e.g., ``locales[]=en_US&locales[]=de_AT``). \ If omitted, all locales are returned. * - rate_cost_schedule_uuid - string|null - Optional. UUID of a schedule entry (recurring or unique pricing config) \ to scope the read to that entry. When omitted, the cost rate's default \ marketing texts are returned. See :ref:`marketing-text-schedule-scope` \ for the per-locale fallback behaviour. **Example request (cost-rate default scope)** .. code-block:: bash curl --location --request GET 'https://example.beenergised.cloud/api/dynamic_pricing/cost_rate_marketing_text?cost_rate_uuid=&locales[]=de_AT' \ --header 'x-api-token: ' **Example request (schedule-entry scope)** .. code-block:: bash curl --location --request GET 'https://example.beenergised.cloud/api/dynamic_pricing/cost_rate_marketing_text?cost_rate_uuid=&rate_cost_schedule_uuid=&locales[]=en_US' \ --header 'x-api-token: ' **Response (200)** .. code-block:: json { "data": { "de_AT": { "short_description": "Test short_description", "description": "Test description", "legal": "Test legal" } } } .. note:: The response always includes all three text type keys per locale. Types \ that have not been set will have an empty string ``""`` as their value. **Error responses** - ``400``: ``rate_cost_schedule_uuid`` is not a valid UUID. .. code-block:: json { "status": "error", "message": "Invalid rate_cost_schedule_uuid format" } - ``404``: Cost rate not found. .. code-block:: json { "status": "error", "message": "Cost rate not found!" } - ``404``: ``rate_cost_schedule_uuid`` is well-formed but does not resolve \ to a schedule entry belonging to this cost rate. .. code-block:: json { "status": "error", "message": "Cost rate schedule not found" } - ``500``: Generic server error. .. code-block:: json { "status": "error", "message": "An unexpected error occured" }