Bump @atproto/api to 0.20.23, drop temporary AA config types

0.20.23 ships `additionalVerificationMethods` on the generated
ConfigRegion type, so the client-side AgeAssuranceConfigRegion
intersection and AgeAssuranceVerificationMethod alias are no longer
needed. Read the field directly off the generated type and type the
debug config as AppBskyAgeassuranceDefs.Config.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
Eric Bailey
2026-06-29 19:26:18 -05:00
parent fc7aefc2b4
commit d683a03a86
5 changed files with 48 additions and 83 deletions
+4 -10
View File
@@ -12,11 +12,9 @@ import {FALLBACK_REGION_CONFIG, MIN_ACCESS_AGE} from '#/ageAssurance/const'
import {useAgeAssuranceServerDataContext} from '#/ageAssurance/data'
import {
AgeAssuranceAccess,
type AgeAssuranceConfigRegion,
type AgeAssuranceFlags,
type AgeAssuranceMetadata,
type AgeAssuranceState,
type AgeAssuranceVerificationMethod,
} from '#/ageAssurance/types'
import {type Geolocation, useGeolocation} from '#/geolocation'
@@ -43,17 +41,13 @@ export function getAgeAssuranceRegionConfigWithFallback(
* Returns the verification methods permitted for a region *in addition to* the
* always-supported KWS flow. Empty when the region doesn't specify any (the
* historical KWS-only behavior).
*
* NOTE: `additionalVerificationMethods` is not yet part of the lexicon, so we
* read it via {@link AgeAssuranceConfigRegion}. See that type for the migration
* note.
*/
export function getRegionAdditionalVerificationMethods(
region: AppBskyAgeassuranceDefs.ConfigRegion,
): AgeAssuranceVerificationMethod[] {
return (
(region as AgeAssuranceConfigRegion).additionalVerificationMethods ?? []
)
): NonNullable<
AppBskyAgeassuranceDefs.ConfigRegion['additionalVerificationMethods']
> {
return region.additionalVerificationMethods ?? []
}
/**