Files
telegram-bot/modules/ContentStore/Service/CapyApiService.cs
T

13 lines
449 B
C#
Raw Normal View History

2023-01-02 19:01:03 +02:00
using Telegram.Bot.Types;
using West.TelegramBot.ContentStore.Model;
2022-08-30 00:48:49 +03:00
namespace West.TelegramBot.ContentStore.Service;
public class CapyApiService : IRandomMediaService
{
public StoreItem StoreItem { get; } = new("capybara", "Капибара", 60, 25);
public async Task<RandomMedia> GetRandomMediaAsync()
{
2023-01-02 19:01:03 +02:00
return new RandomMedia(new InputFileUrl($"https://api.capy.lol/v1/capybara?{new Random().Next(0, 10000)}"));
2022-08-30 00:48:49 +03:00
}
}