credential.json.twig in Apigee Edge 8
Credential
Usage:
{% include 'credential.json.twig' %} Variables:
- credential: The app credential.
File
tests/modules/apigee_mock_api_client/tests/response-templates/credential.json.twigView source
- {#
- /**
- * @file
- * Credential
- *
- * Usage:
- * @code {% include 'credential.json.twig' %} @endcode
- *
- * Variables:
- * - credential: The app credential.
- */
- #}
- {
- "apiProducts": [
- {% for product in credential.apiProducts %}
- {
- "apiproduct": "{{ product.name|default('api_product') }}",
- "status": "{{ product.status|default('approved') }}"
- }{{ loop.last ? '' : ',' }}
- {% endfor %}
- ],
- "attributes": [],
- "consumerKey": "{{ credential.consumerKey|default('dMHy6YlXjGerx7uyZocwP0LOEQgcUSEp') }}",
- "consumerSecret": "{{ credential.consumerSecret|default('dJ8omGPp3CejtANd') }}",
- "expiresAt": "{{ credential.expiresAt|default(1595289603149) }}",
- "issuedAt": "{{ credential.issuedAt|default(1594973277149) }}",
- "scopes": [],
- "status": "{{ credential.status|default('approved') }}"
- }