Add Twitter configuration to docs

This commit is contained in:
Yarmo Mackenbach 2021-03-01 18:26:40 +01:00
parent 30ac7b205d
commit 0bb3a59964
No known key found for this signature in database
GPG key ID: 37367F4AF4087AD1
3 changed files with 32 additions and 5 deletions

View file

@ -16,15 +16,26 @@ Verifies the identity behind the provided **uri** using the **fingerprint**.
**Options**
| Name | Type | Default value | Description |
| ----------------- | ------- | -------------------- | ------------------------------------------------------------------- |
| returnMatchesOnly | boolean | false | only return matching service providers, do not attempt verification |
| proxyPolicy | string | 'adaptive' | when to use a proxy ['adaptive', 'fallback', 'always', 'never'] |
| doipProxyHostname | string | 'proxy.keyoxide.org' | the hostname of the proxy server |
| Name | Type | Default value | Description |
| ------------------ | ------- | -------------------- | ---------------------------------------------------------------------- |
| returnMatchesOnly | boolean | false | only return matching service providers, do not attempt verification |
| proxyPolicy | string | 'adaptive' | when to use a proxy ['adaptive', 'fallback', 'always', 'never'] |
| doipProxyHostname | string | 'proxy.keyoxide.org' | the hostname of the proxy server |
| twitterBearerToken | string | '' | the Twitter API bearer token used for Twitter verification |
| nitterInstance | string | '' | the domain name of the nitter instance to use for Twitter verification |
When the `proxyPolicy` option is to `adaptive`, the chosen strategy is
the one suggested by the service provider.
By default, Twitter accounts are not verified. Either provide a
[Twitter bearer token](https://developer.twitter.com/en/docs/authentication/oauth-2-0/bearer-tokens)
(as `twitterBearerToken`) or the domain name of a Nitter instance (as
`nitterInstance`) to enable Twitter account verification. If both values are
provided, only the Twitter bearer token is used.
Note that Nitter instances are subject to rate limiting which would instantly
break Twitter account verification.
**Returns**
An object with the results of the identity claim verification containing a

View file

@ -19,3 +19,11 @@ Please note you need to include the
```html
<script src="https://cdn.jsdelivr.net/npm/openpgp/dist/openpgp.min.js"></script>
```
## Twitter account verification
By default, Twitter accounts verification has to be enabled by either having a
Twitter developer account or providing a Nitter instance domain.
Please refer to the
[API documentation](/#/api?id=claimsverifyuri-fingerprint-opts).

View file

@ -14,3 +14,11 @@ verifyIdentity('dns:doip.rocks', '9f0048ac0b23301e1f77e994909f6bd6f80f485d')
This snippet works en will verify the [doip.rocks](https://doip.rocks) domain as
linked to Yarmo's cryptographic key using the [dns](serviceproviders/dns.md)
service provider.
## Twitter account verification
By default, Twitter accounts verification has to be enabled by either having a
Twitter developer account or providing a Nitter instance domain.
Please refer to the
[API documentation](/#/api?id=claimsverifyuri-fingerprint-opts).