diff --git a/android/app/build.gradle b/android/app/build.gradle index 53fc908c36..67cbafa16d 100644 --- a/android/app/build.gradle +++ b/android/app/build.gradle @@ -151,6 +151,12 @@ android { } } } + + configurations.all { + resolutionStrategy { + force 'com.google.android.play:core-common:2.0.2' + } + } } dependencies { @@ -173,6 +179,13 @@ dependencies { implementation jscFlavor } + // https://github.com/KjellConnelly/react-native-rate/issues/117 + // https://chat.openai.com/c/ba241381-615e-48b1-baa3-ce3dbc7246b7 + implementation(project(":react-native-rate")) { + exclude group: 'com.google.android.play', module: 'core-common' + exclude group: 'com.google.android.play', module: 'review' + } + implementation 'androidx.multidex:multidex:2.0.1' } diff --git a/app/components/contact-support-button/contact-support-button.tsx b/app/components/contact-support-button/contact-support-button.tsx index 6d9c869d7d..2032b88b87 100644 --- a/app/components/contact-support-button/contact-support-button.tsx +++ b/app/components/contact-support-button/contact-support-button.tsx @@ -10,7 +10,7 @@ import { useAppConfig } from "@app/hooks" export const ContactSupportButton = ({ containerStyle, }: { - containerStyle: StyleProp + containerStyle?: StyleProp }) => { const [showContactSupport, setShowContactSupport] = useState(false) const { LL } = useI18nContext() diff --git a/app/graphql/generated.gql b/app/graphql/generated.gql index f1ba14919e..f884df85f2 100644 --- a/app/graphql/generated.gql +++ b/app/graphql/generated.gql @@ -973,7 +973,11 @@ query fullOnboardingScreen { me { id defaultAccount { - id + ... on ConsumerAccount { + id + onboardingStatus + __typename + } __typename } __typename diff --git a/app/graphql/generated.ts b/app/graphql/generated.ts index fc846cd44e..ca838ee39f 100644 --- a/app/graphql/generated.ts +++ b/app/graphql/generated.ts @@ -82,8 +82,6 @@ export type Scalars = { Username: { input: string; output: string; } /** Unique identifier of a wallet */ WalletId: { input: string; output: string; } - join__FieldSet: { input: string; output: string; } - link__Import: { input: string; output: string; } _FieldSet: { input: string; output: string; } }; @@ -303,6 +301,7 @@ export type ConsumerAccount = Account & { readonly level: AccountLevel; readonly limits: AccountLimits; readonly notificationSettings: NotificationSettings; + readonly onboardingStatus?: Maybe; /** List the quiz questions of the consumer account */ readonly quiz: ReadonlyArray; readonly realtimePrice: RealtimePrice; @@ -1138,7 +1137,6 @@ export type OnChainUsdTxFee = { }; export type OnboardingFlowStartInput = { - readonly accountId: Scalars['String']['input']; readonly firstName: Scalars['String']['input']; readonly lastName: Scalars['String']['input']; }; @@ -1150,6 +1148,18 @@ export type OnboardingFlowStartResult = { readonly workflowRunId: Scalars['String']['output']; }; +export const OnboardingStatus = { + Abandoned: 'ABANDONED', + Approved: 'APPROVED', + AwaitingInput: 'AWAITING_INPUT', + Declined: 'DECLINED', + Error: 'ERROR', + NotStarted: 'NOT_STARTED', + Processing: 'PROCESSING', + Review: 'REVIEW' +} as const; + +export type OnboardingStatus = typeof OnboardingStatus[keyof typeof OnboardingStatus]; export type OneDayAccountLimit = AccountLimit & { readonly __typename: 'OneDayAccountLimit'; /** The rolling time interval value in seconds for the current 24 hour period. */ @@ -1283,8 +1293,6 @@ export type Query = { readonly __typename: 'Query'; readonly accountDefaultWallet: PublicWallet; readonly beta: Scalars['Boolean']['output']; - /** @deprecated Deprecated in favor of realtimePrice */ - readonly btcPrice?: Maybe; readonly btcPriceList?: Maybe>>; readonly businessMapMarkers?: Maybe>>; readonly colorScheme: Scalars['String']['output']; @@ -1292,7 +1300,6 @@ export type Query = { readonly feedbackModalShown: Scalars['Boolean']['output']; readonly globals?: Maybe; readonly hasPromptedSetDefaultAccount: Scalars['Boolean']['output']; - readonly hello?: Maybe; readonly hiddenBalanceToolTip: Scalars['Boolean']['output']; readonly hideBalance: Scalars['Boolean']['output']; readonly innerCircleValue: Scalars['Int']['output']; @@ -1321,11 +1328,6 @@ export type QueryAccountDefaultWalletArgs = { }; -export type QueryBtcPriceArgs = { - currency?: Scalars['DisplayCurrency']['input']; -}; - - export type QueryBtcPriceListArgs = { range: PriceGraphRange; }; @@ -1868,21 +1870,6 @@ export const WelcomeRange = { } as const; export type WelcomeRange = typeof WelcomeRange[keyof typeof WelcomeRange]; -export const Join__Graph = { - Circles: 'CIRCLES', - Galoy: 'GALOY', - Kyc: 'KYC' -} as const; - -export type Join__Graph = typeof Join__Graph[keyof typeof Join__Graph]; -export const Link__Purpose = { - /** `EXECUTION` features provide metadata necessary for operation execution. */ - Execution: 'EXECUTION', - /** `SECURITY` features provide metadata necessary to securely resolve fields. */ - Security: 'SECURITY' -} as const; - -export type Link__Purpose = typeof Link__Purpose[keyof typeof Link__Purpose]; export type MobileUpdateQueryVariables = Exact<{ [key: string]: never; }>; @@ -2064,7 +2051,7 @@ export type OnboardingFlowStartMutation = { readonly __typename: 'Mutation', rea export type FullOnboardingScreenQueryVariables = Exact<{ [key: string]: never; }>; -export type FullOnboardingScreenQuery = { readonly __typename: 'Query', readonly me?: { readonly __typename: 'User', readonly id: string, readonly defaultAccount: { readonly __typename: 'ConsumerAccount', readonly id: string } } | null }; +export type FullOnboardingScreenQuery = { readonly __typename: 'Query', readonly me?: { readonly __typename: 'User', readonly id: string, readonly defaultAccount: { readonly __typename: 'ConsumerAccount', readonly id: string, readonly onboardingStatus?: OnboardingStatus | null } } | null }; export type AddressScreenQueryVariables = Exact<{ [key: string]: never; }>; @@ -3778,7 +3765,10 @@ export const FullOnboardingScreenDocument = gql` me { id defaultAccount { - id + ... on ConsumerAccount { + id + onboardingStatus + } } } } @@ -6881,6 +6871,7 @@ export type ResolversTypes = { OnChainUsdTxFee: ResolverTypeWrapper; OnboardingFlowStartInput: OnboardingFlowStartInput; OnboardingFlowStartResult: ResolverTypeWrapper; + OnboardingStatus: OnboardingStatus; OneDayAccountLimit: ResolverTypeWrapper; OneTimeAuthCode: ResolverTypeWrapper; PageInfo: ResolverTypeWrapper; @@ -6967,10 +6958,6 @@ export type ResolversTypes = { WelcomeLeaderboardInput: WelcomeLeaderboardInput; WelcomeProfile: ResolverTypeWrapper; WelcomeRange: WelcomeRange; - join__FieldSet: ResolverTypeWrapper; - join__Graph: Join__Graph; - link__Import: ResolverTypeWrapper; - link__Purpose: Link__Purpose; }; /** Mapping between all available schema types and the resolvers parents */ @@ -7164,67 +7151,14 @@ export type ResolversParentTypes = { WalletId: Scalars['WalletId']['output']; WelcomeLeaderboardInput: WelcomeLeaderboardInput; WelcomeProfile: WelcomeProfile; - join__FieldSet: Scalars['join__FieldSet']['output']; - link__Import: Scalars['link__Import']['output']; }; -export type Join__EnumValueDirectiveArgs = { - graph: Join__Graph; +export type DeferDirectiveArgs = { + if?: Scalars['Boolean']['input']; + label?: Maybe; }; -export type Join__EnumValueDirectiveResolver = DirectiveResolverFn; - -export type Join__FieldDirectiveArgs = { - external?: Maybe; - graph?: Maybe; - override?: Maybe; - provides?: Maybe; - requires?: Maybe; - type?: Maybe; - usedOverridden?: Maybe; -}; - -export type Join__FieldDirectiveResolver = DirectiveResolverFn; - -export type Join__GraphDirectiveArgs = { - name: Scalars['String']['input']; - url: Scalars['String']['input']; -}; - -export type Join__GraphDirectiveResolver = DirectiveResolverFn; - -export type Join__ImplementsDirectiveArgs = { - graph: Join__Graph; - interface: Scalars['String']['input']; -}; - -export type Join__ImplementsDirectiveResolver = DirectiveResolverFn; - -export type Join__TypeDirectiveArgs = { - extension?: Scalars['Boolean']['input']; - graph: Join__Graph; - isInterfaceObject?: Scalars['Boolean']['input']; - key?: Maybe; - resolvable?: Scalars['Boolean']['input']; -}; - -export type Join__TypeDirectiveResolver = DirectiveResolverFn; - -export type Join__UnionMemberDirectiveArgs = { - graph: Join__Graph; - member: Scalars['String']['input']; -}; - -export type Join__UnionMemberDirectiveResolver = DirectiveResolverFn; - -export type LinkDirectiveArgs = { - as?: Maybe; - for?: Maybe; - import?: Maybe>>; - url?: Maybe; -}; - -export type LinkDirectiveResolver = DirectiveResolverFn; +export type DeferDirectiveResolver = DirectiveResolverFn; export type AccountResolvers = { __resolveType: TypeResolveFn<'ConsumerAccount', ParentType, ContextType>; @@ -7357,6 +7291,7 @@ export type ConsumerAccountResolvers; limits?: Resolver; notificationSettings?: Resolver; + onboardingStatus?: Resolver, ParentType, ContextType>; quiz?: Resolver, ParentType, ContextType>; realtimePrice?: Resolver; transactions?: Resolver, ParentType, ContextType, Partial>; @@ -7809,7 +7744,6 @@ export type PublicWalletResolvers = { accountDefaultWallet?: Resolver>; beta?: Resolver; - btcPrice?: Resolver, ParentType, ContextType, RequireFields>; btcPriceList?: Resolver>>, ParentType, ContextType, RequireFields>; businessMapMarkers?: Resolver>>, ParentType, ContextType>; colorScheme?: Resolver; @@ -7817,7 +7751,6 @@ export type QueryResolvers; globals?: Resolver, ParentType, ContextType>; hasPromptedSetDefaultAccount?: Resolver; - hello?: Resolver, ParentType, ContextType>; hiddenBalanceToolTip?: Resolver; hideBalance?: Resolver; innerCircleValue?: Resolver; @@ -8134,14 +8067,6 @@ export type WelcomeProfileResolvers; }; -export interface Join__FieldSetScalarConfig extends GraphQLScalarTypeConfig { - name: 'join__FieldSet'; -} - -export interface Link__ImportScalarConfig extends GraphQLScalarTypeConfig { - name: 'link__Import'; -} - export type Resolvers = { Account?: AccountResolvers; AccountDeletePayload?: AccountDeletePayloadResolvers; @@ -8275,16 +8200,8 @@ export type Resolvers = { Wallet?: WalletResolvers; WalletId?: GraphQLScalarType; WelcomeProfile?: WelcomeProfileResolvers; - join__FieldSet?: GraphQLScalarType; - link__Import?: GraphQLScalarType; }; export type DirectiveResolvers = { - join__enumValue?: Join__EnumValueDirectiveResolver; - join__field?: Join__FieldDirectiveResolver; - join__graph?: Join__GraphDirectiveResolver; - join__implements?: Join__ImplementsDirectiveResolver; - join__type?: Join__TypeDirectiveResolver; - join__unionMember?: Join__UnionMemberDirectiveResolver; - link?: LinkDirectiveResolver; + defer?: DeferDirectiveResolver; }; diff --git a/app/i18n/en/index.ts b/app/i18n/en/index.ts index db8f7f4f69..f7d730c036 100644 --- a/app/i18n/en/index.ts +++ b/app/i18n/en/index.ts @@ -2767,9 +2767,15 @@ const en: BaseTranslation = { lastName: "Last name", confirmNameContent: "Is the spelling of your name correct?\n\n{firstName: string} {lastName: string}\n\nIt must match the name on your ID.", requirements: "Upgrading your account will increase your limits and give you additional functionality such as transfer to bank account, in selected countries.\n\nYou will have to provide your name, a governement-issued ID and a selfie. We'll start with your name.", - accountVerifiedAlready: "You account has already been verified", - success: "Documents has been successfully received", - error: "There has been an error with the submission of your documents. You can contact the support is the problem persists." + success: "Documents has been succesfully received and will be processed shortly. you can come back to this page to have an update on the status of your onboarding", + error: "There has been an error with the submission of your documents. You can contact the support is the problem persists.", + status: "Your onboarding status is: ", + ABANDONED: "Abandoned", + APPROVED: "Approved", + DECLINED: "Declined", + ERROR: "Error", + PROCESSING: "Processing", + REVIEW: "Review", } } diff --git a/app/i18n/i18n-types.ts b/app/i18n/i18n-types.ts index d6ef2bf115..98f48b121f 100644 --- a/app/i18n/i18n-types.ts +++ b/app/i18n/i18n-types.ts @@ -8679,17 +8679,41 @@ type RootTranslation = { */ requirements: string /** - * Y​o​u​ ​a​c​c​o​u​n​t​ ​h​a​s​ ​a​l​r​e​a​d​y​ ​b​e​e​n​ ​v​e​r​i​f​i​e​d - */ - accountVerifiedAlready: string - /** - * D​o​c​u​m​e​n​t​s​ ​h​a​s​ ​b​e​e​n​ ​s​u​c​c​e​s​s​f​u​l​l​y​ ​r​e​c​e​i​v​e​d + * D​o​c​u​m​e​n​t​s​ ​h​a​s​ ​b​e​e​n​ ​s​u​c​c​e​s​f​u​l​l​y​ ​r​e​c​e​i​v​e​d​ ​a​n​d​ ​w​i​l​l​ ​b​e​ ​p​r​o​c​e​s​s​e​d​ ​s​h​o​r​t​l​y​.​ ​y​o​u​ ​c​a​n​ ​c​o​m​e​ ​b​a​c​k​ ​t​o​ ​t​h​i​s​ ​p​a​g​e​ ​t​o​ ​h​a​v​e​ ​a​n​ ​u​p​d​a​t​e​ ​o​n​ ​t​h​e​ ​s​t​a​t​u​s​ ​o​f​ ​y​o​u​r​ ​o​n​b​o​a​r​d​i​n​g */ success: string /** * T​h​e​r​e​ ​h​a​s​ ​b​e​e​n​ ​a​n​ ​e​r​r​o​r​ ​w​i​t​h​ ​t​h​e​ ​s​u​b​m​i​s​s​i​o​n​ ​o​f​ ​y​o​u​r​ ​d​o​c​u​m​e​n​t​s​.​ ​Y​o​u​ ​c​a​n​ ​c​o​n​t​a​c​t​ ​t​h​e​ ​s​u​p​p​o​r​t​ ​i​s​ ​t​h​e​ ​p​r​o​b​l​e​m​ ​p​e​r​s​i​s​t​s​. */ error: string + /** + * Y​o​u​r​ ​o​n​b​o​a​r​d​i​n​g​ ​s​t​a​t​u​s​ ​i​s​:​ + */ + status: string + /** + * A​b​a​n​d​o​n​e​d + */ + ABANDONED: string + /** + * A​p​p​r​o​v​e​d + */ + APPROVED: string + /** + * D​e​c​l​i​n​e​d + */ + DECLINED: string + /** + * E​r​r​o​r + */ + ERROR: string + /** + * P​r​o​c​e​s​s​i​n​g + */ + PROCESSING: string + /** + * R​e​v​i​e​w + */ + REVIEW: string } } @@ -17256,17 +17280,41 @@ export type TranslationFunctions = { */ requirements: () => LocalizedString /** - * You account has already been verified - */ - accountVerifiedAlready: () => LocalizedString - /** - * Documents has been successfully received + * Documents has been succesfully received and will be processed shortly. you can come back to this page to have an update on the status of your onboarding */ success: () => LocalizedString /** * There has been an error with the submission of your documents. You can contact the support is the problem persists. */ error: () => LocalizedString + /** + * Your onboarding status is: + */ + status: () => LocalizedString + /** + * Abandoned + */ + ABANDONED: () => LocalizedString + /** + * Approved + */ + APPROVED: () => LocalizedString + /** + * Declined + */ + DECLINED: () => LocalizedString + /** + * Error + */ + ERROR: () => LocalizedString + /** + * Processing + */ + PROCESSING: () => LocalizedString + /** + * Review + */ + REVIEW: () => LocalizedString } } diff --git a/app/i18n/raw-i18n/source/en.json b/app/i18n/raw-i18n/source/en.json index 99cbc0012b..2dbfdc60bd 100644 --- a/app/i18n/raw-i18n/source/en.json +++ b/app/i18n/raw-i18n/source/en.json @@ -2659,8 +2659,14 @@ "lastName": "Last name", "confirmNameContent": "Is the spelling of your name correct?\n\n{firstName: string} {lastName: string}\n\nIt must match the name on your ID.", "requirements": "Upgrading your account will increase your limits and give you additional functionality such as transfer to bank account, in selected countries.\n\nYou will have to provide your name, a governement-issued ID and a selfie. We'll start with your name.", - "accountVerifiedAlready": "You account has already been verified", - "success": "Documents has been successfully received", - "error": "There has been an error with the submission of your documents. You can contact the support is the problem persists." + "success": "Documents has been succesfully received and will be processed shortly. you can come back to this page to have an update on the status of your onboarding", + "error": "There has been an error with the submission of your documents. You can contact the support is the problem persists.", + "status": "Your onboarding status is: ", + "ABANDONED": "Abandoned", + "APPROVED": "Approved", + "DECLINED": "Declined", + "ERROR": "Error", + "PROCESSING": "Processing", + "REVIEW": "Review" } } diff --git a/app/screens/full-onboarding-flow/full-onboarding-flow.stories.tsx b/app/screens/full-onboarding-flow/full-onboarding-flow.stories.tsx index ab843f3423..25082b2563 100644 --- a/app/screens/full-onboarding-flow/full-onboarding-flow.stories.tsx +++ b/app/screens/full-onboarding-flow/full-onboarding-flow.stories.tsx @@ -1,9 +1,9 @@ import * as React from "react" import { StoryScreen } from "../../../.storybook/views" -import { IsAuthedContextProvider } from "../../graphql/is-authed-context" import { MockedProvider } from "@apollo/client/testing" import { createCache } from "../../graphql/cache" import { FullOnboardingFlowScreen } from "./full-onboarding-flow" +import { FullOnboardingScreenDocument } from "../../graphql/generated" export default { title: "Full onboarding screen", @@ -11,10 +11,56 @@ export default { decorators: [(Story) => {Story()}], } +const notStarted = [ + { + request: { + query: FullOnboardingScreenDocument, + }, + result: { + data: { + me: { + id: "id", + defaultAccount: { + id: "id", + onboardingStatus: "NOT_STARTED", + __typename: "ConsumerAccount", + }, + __typename: "User", + }, + }, + }, + }, +] + +const approved = [ + { + request: { + query: FullOnboardingScreenDocument, + }, + result: { + data: { + me: { + id: "id", + defaultAccount: { + id: "id", + onboardingStatus: "APPROVED", + __typename: "ConsumerAccount", + }, + __typename: "User", + }, + }, + }, + }, +] + export const Default = () => ( - - - - + + + +) + +export const Approved = () => ( + + ) diff --git a/app/screens/full-onboarding-flow/full-onboarding-flow.tsx b/app/screens/full-onboarding-flow/full-onboarding-flow.tsx index 7cc8202c5e..6e1296e4d3 100644 --- a/app/screens/full-onboarding-flow/full-onboarding-flow.tsx +++ b/app/screens/full-onboarding-flow/full-onboarding-flow.tsx @@ -1,17 +1,19 @@ import { gql } from "@apollo/client" import { GaloyPrimaryButton } from "@app/components/atomic/galoy-primary-button" +import { ContactSupportButton } from "@app/components/contact-support-button/contact-support-button" import { Screen } from "@app/components/screen" import { + OnboardingStatus, useFullOnboardingScreenQuery, useOnboardingFlowStartMutation, } from "@app/graphql/generated" -import { AccountLevel, useLevel } from "@app/graphql/level-context" import { useI18nContext } from "@app/i18n/i18n-react" import { isIos } from "@app/utils/helper" import Onfido, { OnfidoTheme } from "@onfido/react-native-sdk" -import { Input, Text, makeStyles } from "@rneui/themed" +import { useNavigation } from "@react-navigation/native" +import { Input, Text, makeStyles, useTheme } from "@rneui/themed" import React, { useState } from "react" -import { Alert, View } from "react-native" +import { ActivityIndicator, Alert, View } from "react-native" gql` mutation onboardingFlowStart($input: OnboardingFlowStartInput!) { @@ -26,21 +28,29 @@ gql` me { id defaultAccount { - id + ... on ConsumerAccount { + id + onboardingStatus + } } } } ` export const FullOnboardingFlowScreen: React.FC = () => { + const navigation = useNavigation() + const { LL } = useI18nContext() + const { + theme: { colors }, + } = useTheme() + const styles = useStyles() - const { currentLevel } = useLevel() + const { data, loading } = useFullOnboardingScreenQuery() - const { data } = useFullOnboardingScreenQuery() - const accountId = data?.me?.defaultAccount?.id + const onboardingStatus = data?.me?.defaultAccount?.onboardingStatus const [onboardingFlowStart] = useOnboardingFlowStartMutation() @@ -62,13 +72,8 @@ export const FullOnboardingFlowScreen: React.FC = () => { } const onfidoStart = async () => { - if (!accountId) { - console.log("no account id") - return - } - const res = await onboardingFlowStart({ - variables: { input: { accountId, firstName, lastName } }, + variables: { input: { firstName, lastName } }, }) const workflowRunId = res.data?.onboardingFlowStart?.workflowRunId @@ -90,21 +95,64 @@ export const FullOnboardingFlowScreen: React.FC = () => { try { /* eslint @typescript-eslint/ban-ts-comment: "off" */ // @ts-expect-error - const res = await Onfido.start({ + await Onfido.start({ sdkToken, theme: OnfidoTheme.AUTOMATIC, workflowRunId, }) - Alert.alert(LL.FullOnboarding.success()) - console.log(res, "success") + Alert.alert(LL.common.success(), LL.FullOnboarding.success(), [ + { + text: LL.common.ok(), + onPress: () => { + navigation.goBack() + }, + }, + ]) } catch (err) { - Alert.alert(LL.FullOnboarding.error()) - console.log(err, "error") + console.error(err, "error") + let message = "" + if (err instanceof Error) { + message = err.message + } + Alert.alert( + LL.FullOnboarding.error(), + `${LL.GaloyAddressScreen.somethingWentWrong()}\n\n${message}`, + [ + { + text: LL.common.ok(), + onPress: () => { + navigation.goBack() + }, + }, + ], + ) } } - if (currentLevel === AccountLevel.Two) { + if (loading) { + return ( + + + + + + ) + } + + if ( + onboardingStatus === OnboardingStatus.Abandoned || + onboardingStatus === OnboardingStatus.Approved || + onboardingStatus === OnboardingStatus.Declined || + onboardingStatus === OnboardingStatus.Error || + onboardingStatus === OnboardingStatus.Processing || + onboardingStatus === OnboardingStatus.Review + ) { return ( { keyboardOffset="navigationHeader" style={styles.screenStyle} > - {LL.FullOnboarding.accountVerifiedAlready()} + {`${LL.FullOnboarding.status()}${LL.FullOnboarding[onboardingStatus]()}.`} + ) } @@ -164,4 +216,6 @@ const useStyles = makeStyles(() => ({ flex: 1, justifyContent: "flex-end", }, + + verticalAlignment: { flex: 1, justifyContent: "center", alignItems: "center" }, })) diff --git a/codegen.yml b/codegen.yml index 01995dfb81..93481ed72a 100644 --- a/codegen.yml +++ b/codegen.yml @@ -1,6 +1,6 @@ overwrite: true -# schema: "https://api.staging.galoy.io/graphql" -schema: "./supergraph.graphql" +schema: "https://api.staging.galoy.io/graphql" +# schema: "./supergraph.graphql" documents: - "app/**/*.ts" - "app/**/*.tsx" diff --git a/supergraph.graphql b/supergraph.graphql index 809c716fc5..17948af9f8 100644 --- a/supergraph.graphql +++ b/supergraph.graphql @@ -290,6 +290,7 @@ type ConsumerAccount implements Account @join__implements(graph: GALOY, interface: "Account") @join__type(graph: CIRCLES, key: "id") @join__type(graph: GALOY) + @join__type(graph: KYC, key: "id") { id: ID! welcomeProfile: WelcomeProfile @join__field(graph: CIRCLES) @@ -327,6 +328,7 @@ type ConsumerAccount implements Account walletIds: [WalletId] ): TransactionConnection @join__field(graph: GALOY) wallets: [Wallet!]! @join__field(graph: GALOY) + onboardingStatus: OnboardingStatus @join__field(graph: KYC) } """ @@ -1065,7 +1067,6 @@ input OnboardingFlowStartInput { firstName: String! lastName: String! - accountId: String! } type OnboardingFlowStartResult @@ -1076,6 +1077,19 @@ type OnboardingFlowStartResult tokenIos: String! } +enum OnboardingStatus + @join__type(graph: KYC) +{ + NOT_STARTED @join__enumValue(graph: KYC) + AWAITING_INPUT @join__enumValue(graph: KYC) + PROCESSING @join__enumValue(graph: KYC) + ABANDONED @join__enumValue(graph: KYC) + ERROR @join__enumValue(graph: KYC) + APPROVED @join__enumValue(graph: KYC) + REVIEW @join__enumValue(graph: KYC) + DECLINED @join__enumValue(graph: KYC) +} + """An address for an on-chain bitcoin destination""" scalar OnChainAddress @join__type(graph: GALOY) @@ -1348,7 +1362,6 @@ type Query { welcomeLeaderboard(input: WelcomeLeaderboardInput!): Leaderboard! @join__field(graph: CIRCLES) accountDefaultWallet(username: Username!, walletCurrency: WalletCurrency): PublicWallet! @join__field(graph: GALOY) - btcPrice(currency: DisplayCurrency! = "USD"): Price @join__field(graph: GALOY) @deprecated(reason: "Deprecated in favor of realtimePrice") btcPriceList(range: PriceGraphRange!): [PricePoint] @join__field(graph: GALOY) businessMapMarkers: [MapMarker] @join__field(graph: GALOY) currencyList: [Currency!]! @join__field(graph: GALOY) @@ -1365,7 +1378,6 @@ type Query realtimePrice(currency: DisplayCurrency = "USD"): RealtimePrice! @join__field(graph: GALOY) userDefaultWalletId(username: Username!): WalletId! @join__field(graph: GALOY) @deprecated(reason: "will be migrated to AccountDefaultWalletId") usernameAvailable(username: Username!): Boolean @join__field(graph: GALOY) - hello: String @join__field(graph: KYC) } type Quiz