Travis Yaml does not have support to get Pull Request body message

Following the documentation [1] to see all variables to use its able to use eg. TRAVIS_PULL_REQUEST_BRANCH , but it is not available to read the content of Pull Request body message, since the initial message or an array of messages.

1 - Environment Variables - Travis CI

Use Github API to get those:

https://docs.github.com/en/rest/reference/pulls#get-a-pull-request

I have problems to have access in the enterprise environment, the curl command return the redirect page instead the content.

curl -L makes cURL follow redirects (see its documentation for more info).
If you don’t have access to Github (or wherever your code repo is hosted) from your Enterprise Travis environment, that’s something to ask your network administrators.
Can’t say anything more specific without seeing the build. If it’s not publicly accessible, you need to reach Enterprise support.

Imprint