Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

128
Views
Graph QL request AWS Amplify

I am trying to query Amplify to get data from a graphQl endpoint. I am sending the data to the backend successfully. Below is the request from GraphQL

  const getFixtures = async () => {
    const clubProfile = await DataStore.query(ClubProfile, c => c.id(userUuid));
    setFixturesListData(clubProfile.fixtures);
    console.log('fixtures here', clubProfile);
  };

The output of the console is: fixtures here [] (just an empty array)

The model is:

export declare class ClubProfile {
  readonly id: string;
  readonly club_email?: string | null;
  readonly club_name?: string | null;
  readonly club_number?: string | null;
  readonly club_description?: string | null;
  readonly club_website?: string | null;
  readonly club_teams?: string | null;
  readonly createdAt?: string | null;
  readonly updatedAt?: string | null;
  constructor(init: ModelInit<ClubProfile, ClubProfileMetaData>);
  static copyOf(source: ClubProfile, mutator: (draft: MutableModel<ClubProfile, ClubProfileMetaData>) => MutableModel<ClubProfile, ClubProfileMetaData> | void): ClubProfile;
}

I am trying different options and getting no success.

When I send the data to the backend:

    const clubInfo = async () => {
      let uuid = customerInfo.customerInfo.attributes.sub;
      const newClub = {
        id: uuid,
        club_name: clubName,
        club_email: clubEmail,
        club_number: clubPhone,
        club_location: clubLocation,
        club_website: 'https://www.clubWebsite.com',
        club_teams: {clubTeams},
        club_description: 'clubDescription',
      };
      await DataStore.save(new ClubProfile(newClub));
      console.log('newClub', newClub);
      setNewClub(newClub);
    };
    clubInfo();
  }
about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!