Files
notifications-admin/app/templates/views/api/keys.html

69 lines
2.2 KiB
HTML
Raw Normal View History

2015-12-14 16:53:07 +00:00
{% extends "withnav_template.html" %}
{% from "components/table.html" import list_table, field, hidden_field_heading %}
{% from "components/page-header.html" import page_header %}
2023-08-30 11:07:38 -04:00
{% from "components/components/button/macro.njk" import usaButton %}
{% from "components/components/back-link/macro.njk" import usaBackLink %}
{% block service_page_title %}
API keys
{% endblock %}
{% block backLink %}
2023-08-30 11:07:38 -04:00
{{ usaBackLink({ "href": url_for('main.api_integration', service_id=current_service.id) }) }}
{% endblock %}
2015-12-14 16:53:07 +00:00
{% block maincolumn_content %}
{{ page_header('API keys') }}
<div class="body-copy-table">
{% call(item, row_number) list_table(
current_service.api_keys,
2019-09-13 12:54:56 +01:00
empty_message="You have not created any API keys yet",
caption="API keys",
caption_visible=false,
field_headings=[
'API keys',
'Action'
],
field_headings_visible=False
) %}
{% call field() %}
<div class="file-list">
{{ item.name }}
<div class="hint">
{% if item.key_type == 'normal' %}
Live sends to anyone
{% elif item.key_type == 'team' %}
Rename ‘whitelist’ to ‘guest list’ in UI This commit changes all the places where a user would see the term ‘whitelist’ in the content of page to say guestlist instead. We’re removing the term ‘whitelist’ for two reasons. The first reason is that we agree with the National Cyber Security Centre say: > It's fairly common to say whitelisting and blacklisting to describe > desirable and undesirable things in cyber security. For instance, when > talking about which applications you will allow or deny on your > corporate network; or deciding which bad passwords you want your users > not to be able to use. > However, there's an issue with the terminology. It only makes sense if > you equate white with 'good, permitted, safe' and black with 'bad, > dangerous, forbidden'. There are some obvious problems with this. So > in the name of helping to stamp out racism in cyber security, we will > avoid this casually pejorative wording on our website in the future. > No, it's not the biggest issue in the world - but to borrow a slogan > from elsewhere: every little helps. – https://www.ncsc.gov.uk/blog-post/terminology-its-not-black-and-white The second reason is that we’ve observed some users think that they have to put recipients in the whitelist even when they’re already with in the team. We think that the term ‘whitelist’ might be reinforcing this mental model because of how ‘whitelists’ might work in other applications. We considered the following alternatives or concepts: - Development - Recipients - Sandbox - Extended team - Smoke test recipients - Allowed - Nominated - Bonus - Additional - Safe - Team list - Trusted contacts - Designated people - Guest list - Team key list We also considered not giving it a name, and explaining it as a nuance of how the team key works. After mocking this up it felt more disjoined. We think it’s still useful for the thing to have a name so that it’s easy to refer to between the docs and the UI. We like the term ‘guest list’ because: - of how it sits with team members – members and guests in the abstract - a guest list is a concept that a lot of people will be familiar with – a list of people who can access a thing - ‘guest’ is very different to ‘recipient’ – we want to mitigate any confusion between this and the (emergency) contact lists
2020-06-12 09:00:08 +01:00
Team and guest list limits who you can send to
{% elif item.key_type == 'test' %}
Test pretends to send messages
{% endif %}
</div>
</div>
{% endcall %}
{% if item.expiry_date %}
{% call field(align='right') %}
2024-03-18 15:10:26 -07:00
<span class='hint'>Revoked {{ item.expiry_date|format_datetime_table }}</span>
{% endcall %}
{% else %}
{% call field(align='right', status='error') %}
<a class="usa-link usa-link--destructive" href='{{ url_for('.revoke_api_key', service_id=current_service.id, key_id=item.id) }}'>
2023-06-16 14:55:24 -04:00
Revoke<span class="usa-sr-only"> {{ item.name }}</span>
</a>
{% endcall %}
{% endif %}
{% endcall %}
</div>
<div class="js-stick-at-bottom-when-scrolling">
2023-08-30 11:07:38 -04:00
{{ usaButton({
"element": "a",
"text": "Create an API key",
"href": url_for('.create_api_key', service_id=current_service.id),
"classes": "govuk-button--secondary"
}) }}
</div>
{% endblock %}