I've been coding a simple pool downloader in C#, getting pool json works fine but when fetching the individual post jsons all the fields are null.
I've seen other threads with similar questions but I don't think I need to use my API key just to get a direct link and download it.
Below is a code snippet of when it attempts to download the picture:
client.Headers.Clear(); client.Headers.Add("user-agent", "PoolDownloaderNET/0.01 (by NotVila on e621)"); string jsonFile = client.DownloadString($"https://e621.net/posts/{postIDs[i]}.json"); var File = JsonSerializer.Deserialize<File>(jsonFile); client.DownloadFile($"{posts.url}", $"./{postID}.{posts.ext}");
Below is a snippet of the fields it fetches from the json
internal class File { public string url { get; set; } public string ext { get; set; } }
I've been trying to figure how to make this work for the past couple of days, thanks in advance :)