How to pass bitrise.yml to POST /apps/{app-slug}/bitrise.yml

I need create a new app via api and setting it up based on settings of other app.
I can get bitrise.yml for the app via Bitrise Swagger UI

How can I apply this config for other app via Bitrise Swagger UI?
How should it be formatted to pass to body of POST request?

Hello,

I would recommend reviewing Updating a new bitrise.yml file. It provides instructions and an example.

Cathy

Thank you for reply.

I tried the example you recommend but I got the following:

I found.
This is needed to escape all line breaks with \ n
and " with \ ‘’ and so on.