get Instance of 'DocumentList' instead of json "` Client client = Client(); Databases databases = Databases(client);
TypeScript
client
.setEndpoint(vals.endPoint) // Your API Endpoint
.setProject(vals.projectId) // Your project ID
;
Future result = databases.listDocuments(
databaseId: '65cf70e3676fdf409798',
collectionId: 'main_list_institutions',
);
result.then((response) {
print(response);
}).catchError((error) {
print(error.response);
});
"`
TL;DR
Developers are getting an instance of 'DocumentList' instead of a JSON response when trying to retrieve data from a database. They are using the 'Client' and 'Databases' classes to set up the API endpoint and project ID. After that, they call the 'listDocuments' method to fetch the documents with specified database and collection IDs. However, the response they receive is an instance of 'DocumentList' instead of the expected JSON format.
Solution: It seems like the 'listDocuments' method is returning a 'DocumentList' object which represents the list of documents. Developers should check the documentation or reach out to the APIRecommended threads
- [SOLVED] curl error Number: 6 — function...
Hello, I invested a lot of time in this error in a fresh install of appwrite 1.8.1 and lasted until fix, this if for helping anyone that can have the same weird...
- android platform invaild origina
It happened today suddenly. Our app says invalid origin. And appwrite cloud says every time we tried to add the app to it: "param platformId" is not optional.
- Team invite - 500 error - no email
When executing ```dart await _repository.teams.createMembership( teamId: event.listId, roles: ['member'], email: event.email, url: 'xxxx', ); ``` I se...