chore: cleanup
This commit is contained in:
parent
7ceb8f656e
commit
b15a77557e
@ -8,16 +8,17 @@ namespace JOBot.Backend.Controllers;
|
|||||||
public class HeadHunterHookController(HeadHunterService hhService)
|
public class HeadHunterHookController(HeadHunterService hhService)
|
||||||
: ControllerBase
|
: ControllerBase
|
||||||
{
|
{
|
||||||
|
|
||||||
[HttpGet]
|
[HttpGet]
|
||||||
public async Task<IActionResult> Get(int userId, string? error, string code)
|
public async Task<IActionResult> Get(int userId, string? error, string code)
|
||||||
{
|
{
|
||||||
var res = await hhService.AuthUser(userId, code, error);
|
var res = await hhService.AuthUser(userId, code, error);
|
||||||
return res switch
|
return res switch
|
||||||
{
|
{
|
||||||
HeadHunterService.Status.Success => Ok("Авторизация завершена успешно. Вернитесь в Telegram для продолжения."),
|
HeadHunterService.Status.Success => Ok(
|
||||||
|
"Авторизация завершена успешно. Вернитесь в Telegram для продолжения."),
|
||||||
HeadHunterService.Status.UserNotFoundError => NotFound("Пользователь не найден."),
|
HeadHunterService.Status.UserNotFoundError => NotFound("Пользователь не найден."),
|
||||||
_ => BadRequest("Авторизация завершена с ошибкой. Вернитесь в Telegram для продолжения.") //TODO: Add resource
|
_ => BadRequest(
|
||||||
|
"Авторизация завершена с ошибкой. Вернитесь в Telegram для продолжения.") //TODO: Add resource
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -1,8 +1,8 @@
|
|||||||
namespace JOBot.Backend.DAL.Context;
|
using JOBot.Backend.DAL.Models;
|
||||||
|
|
||||||
using Models;
|
|
||||||
using Microsoft.EntityFrameworkCore;
|
using Microsoft.EntityFrameworkCore;
|
||||||
|
|
||||||
|
namespace JOBot.Backend.DAL.Context;
|
||||||
|
|
||||||
public class AppDbContext(DbContextOptions<AppDbContext> options) : DbContext(options)
|
public class AppDbContext(DbContextOptions<AppDbContext> options) : DbContext(options)
|
||||||
{
|
{
|
||||||
public DbSet<User> Users { get; set; }
|
public DbSet<User> Users { get; set; }
|
||||||
|
@ -9,10 +9,10 @@ public class User
|
|||||||
{
|
{
|
||||||
public Guid Id { get; set; }
|
public Guid Id { get; set; }
|
||||||
|
|
||||||
[Key]
|
[Key] public required long UserId { get; set; }
|
||||||
public required long UserId { get; set; }
|
|
||||||
[MaxLength(255)]
|
[MaxLength(255)] public string? Username { get; set; }
|
||||||
public string? Username { get; set; }
|
|
||||||
public DateTime CreatedAt { get; set; } = DateTime.UtcNow;
|
public DateTime CreatedAt { get; set; } = DateTime.UtcNow;
|
||||||
|
|
||||||
[MaxLength(255)] public string? AccessToken { get; set; } = null;
|
[MaxLength(255)] public string? AccessToken { get; set; } = null;
|
||||||
|
@ -3,12 +3,12 @@ using System.Text.Json.Serialization;
|
|||||||
namespace JOBot.Backend.DTOs.HeadHunterHook;
|
namespace JOBot.Backend.DTOs.HeadHunterHook;
|
||||||
|
|
||||||
public record HeadHunterTokenResponseDto(
|
public record HeadHunterTokenResponseDto(
|
||||||
[property:JsonPropertyName("access_token")]
|
[property: JsonPropertyName("access_token")]
|
||||||
string AccessToken,
|
string AccessToken,
|
||||||
[property:JsonPropertyName("expires_in")]
|
[property: JsonPropertyName("expires_in")]
|
||||||
int ExpiresIn,
|
int ExpiresIn,
|
||||||
[property:JsonPropertyName("refresh_token")]
|
[property: JsonPropertyName("refresh_token")]
|
||||||
string RefreshToken,
|
string RefreshToken,
|
||||||
[property:JsonPropertyName("token_type")]
|
[property: JsonPropertyName("token_type")]
|
||||||
string TokenType
|
string TokenType
|
||||||
);
|
);
|
@ -1,34 +1,34 @@
|
|||||||
<Project Sdk="Microsoft.NET.Sdk.Web">
|
<Project Sdk="Microsoft.NET.Sdk.Web">
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFramework>net9.0</TargetFramework>
|
<TargetFramework>net9.0</TargetFramework>
|
||||||
<Nullable>enable</Nullable>
|
<Nullable>enable</Nullable>
|
||||||
<ImplicitUsings>enable</ImplicitUsings>
|
<ImplicitUsings>enable</ImplicitUsings>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<PackageReference Include="Google.Protobuf" Version="3.30.2" />
|
<PackageReference Include="Google.Protobuf" Version="3.30.2"/>
|
||||||
<PackageReference Include="Grpc.AspNetCore" Version="2.71.0" />
|
<PackageReference Include="Grpc.AspNetCore" Version="2.71.0"/>
|
||||||
<PackageReference Include="Grpc.AspNetCore.Server.Reflection" Version="2.71.0" />
|
<PackageReference Include="Grpc.AspNetCore.Server.Reflection" Version="2.71.0"/>
|
||||||
<PackageReference Include="Grpc.Tools" Version="2.71.0">
|
<PackageReference Include="Grpc.Tools" Version="2.71.0">
|
||||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||||
<PrivateAssets>all</PrivateAssets>
|
<PrivateAssets>all</PrivateAssets>
|
||||||
</PackageReference>
|
</PackageReference>
|
||||||
<PackageReference Include="JetBrains.Annotations" Version="2024.3.0" />
|
<PackageReference Include="JetBrains.Annotations" Version="2024.3.0"/>
|
||||||
<PackageReference Include="Microsoft.EntityFrameworkCore.Design" Version="9.0.4">
|
<PackageReference Include="Microsoft.EntityFrameworkCore.Design" Version="9.0.4">
|
||||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||||
<PrivateAssets>all</PrivateAssets>
|
<PrivateAssets>all</PrivateAssets>
|
||||||
</PackageReference>
|
</PackageReference>
|
||||||
<PackageReference Include="Npgsql.EntityFrameworkCore.PostgreSQL" Version="9.0.4" />
|
<PackageReference Include="Npgsql.EntityFrameworkCore.PostgreSQL" Version="9.0.4"/>
|
||||||
<PackageReference Include="RabbitMQ.Client" Version="7.1.2" />
|
<PackageReference Include="RabbitMQ.Client" Version="7.1.2"/>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Protobuf Include="..\Proto\*" GrpcServices="Server"></Protobuf>
|
<Protobuf Include="..\Proto\*" GrpcServices="Server"></Protobuf>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Folder Include="Data\Migrations\" />
|
<Folder Include="Data\Migrations\"/>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
</Project>
|
</Project>
|
@ -15,20 +15,28 @@ public class HeadHunterService(
|
|||||||
IOptions<HeadHunterConfig> config,
|
IOptions<HeadHunterConfig> config,
|
||||||
AppDbContext dbContext)
|
AppDbContext dbContext)
|
||||||
{
|
{
|
||||||
|
public enum Status
|
||||||
|
{
|
||||||
|
UserAuthRejectedError,
|
||||||
|
HeadHunterAuthRejectedError,
|
||||||
|
UserNotFoundError,
|
||||||
|
HeadHunterResponseDeserializationFailedError,
|
||||||
|
Success
|
||||||
|
}
|
||||||
|
|
||||||
private readonly HeadHunterConfig _config = config.Value;
|
private readonly HeadHunterConfig _config = config.Value;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Generate HeadHunter oauth authorization link
|
/// Generate HeadHunter oauth authorization link
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="userId">Telegram UserId</param>
|
/// <param name="userId">Telegram UserId</param>
|
||||||
/// <returns>Link for auth</returns>
|
/// <returns>Link for auth</returns>
|
||||||
public string GenerateAuthLink(long userId)
|
public string GenerateAuthLink(long userId)
|
||||||
{
|
{
|
||||||
|
|
||||||
return string.Format(_config.Links.AuthLink, [_config.ClientId, GetRedirectUrl(userId)]);
|
return string.Format(_config.Links.AuthLink, [_config.ClientId, GetRedirectUrl(userId)]);
|
||||||
}
|
}
|
||||||
|
|
||||||
public async Task<Status> AuthUser(int userId, string authorizationCode, string? error)
|
public async Task<Status> AuthUser(int userId, string authorizationCode, string? error) //TODO: Разбить этот метод
|
||||||
{
|
{
|
||||||
logger.LogInformation($"Authorization for user {userId} in process...");
|
logger.LogInformation($"Authorization for user {userId} in process...");
|
||||||
|
|
||||||
@ -99,7 +107,7 @@ public class HeadHunterService(
|
|||||||
RabbitQueues.AuthQueue,
|
RabbitQueues.AuthQueue,
|
||||||
Encoding.UTF8.GetBytes(userId.ToString()));
|
Encoding.UTF8.GetBytes(userId.ToString()));
|
||||||
|
|
||||||
logger.LogInformation($"RabbitMQ event was created");
|
logger.LogInformation("RabbitMQ event was created");
|
||||||
|
|
||||||
return Status.Success;
|
return Status.Success;
|
||||||
}
|
}
|
||||||
@ -114,13 +122,4 @@ public class HeadHunterService(
|
|||||||
Query = $"?userId={userId}"
|
Query = $"?userId={userId}"
|
||||||
}.ToString();
|
}.ToString();
|
||||||
}
|
}
|
||||||
|
|
||||||
public enum Status
|
|
||||||
{
|
|
||||||
UserAuthRejectedError,
|
|
||||||
HeadHunterAuthRejectedError,
|
|
||||||
UserNotFoundError,
|
|
||||||
HeadHunterResponseDeserializationFailedError,
|
|
||||||
Success
|
|
||||||
}
|
|
||||||
}
|
}
|
@ -1,4 +1,3 @@
|
|||||||
using Google.Protobuf.WellKnownTypes;
|
|
||||||
using Grpc.Core;
|
using Grpc.Core;
|
||||||
using JOBot.Backend.DAL.Context;
|
using JOBot.Backend.DAL.Context;
|
||||||
using JOBot.Backend.DAL.Models;
|
using JOBot.Backend.DAL.Models;
|
||||||
@ -11,7 +10,7 @@ namespace JOBot.Backend.Services.gRPC;
|
|||||||
public class UserService(AppDbContext dbContext, HeadHunterService hhService) : Proto.User.UserBase
|
public class UserService(AppDbContext dbContext, HeadHunterService hhService) : Proto.User.UserBase
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Create user
|
/// Create user
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="request"></param>
|
/// <param name="request"></param>
|
||||||
/// <param name="_"></param>
|
/// <param name="_"></param>
|
||||||
@ -32,7 +31,7 @@ public class UserService(AppDbContext dbContext, HeadHunterService hhService) :
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Get user for client
|
/// Get user for client
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="request"></param>
|
/// <param name="request"></param>
|
||||||
/// <param name="_"></param>
|
/// <param name="_"></param>
|
||||||
@ -46,7 +45,7 @@ public class UserService(AppDbContext dbContext, HeadHunterService hhService) :
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Accept EULA for user
|
/// Accept EULA for user
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="request"></param>
|
/// <param name="request"></param>
|
||||||
/// <param name="_"></param>
|
/// <param name="_"></param>
|
||||||
@ -74,7 +73,7 @@ public class UserService(AppDbContext dbContext, HeadHunterService hhService) :
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Throw RPCException if user not found
|
/// Throw RPCException if user not found
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="user"></param>
|
/// <param name="user"></param>
|
||||||
/// <exception cref="RpcException"></exception>
|
/// <exception cref="RpcException"></exception>
|
||||||
|
@ -23,7 +23,7 @@ public class Startup(IConfiguration configuration)
|
|||||||
HostName = "jobot-rabbitmq"
|
HostName = "jobot-rabbitmq"
|
||||||
}.CreateConnectionAsync();
|
}.CreateConnectionAsync();
|
||||||
await using var channel = await rabbitMqConnection.CreateChannelAsync();
|
await using var channel = await rabbitMqConnection.CreateChannelAsync();
|
||||||
await channel.QueueDeclareAsync(RabbitQueues.AuthQueue, false, false, autoDelete: false);
|
await channel.QueueDeclareAsync(RabbitQueues.AuthQueue, false, false, false);
|
||||||
services.AddSingleton(channel);
|
services.AddSingleton(channel);
|
||||||
|
|
||||||
services.AddDbContext<AppDbContext>(options =>
|
services.AddDbContext<AppDbContext>(options =>
|
||||||
|
@ -1,35 +1,35 @@
|
|||||||
{
|
{
|
||||||
"Logging": {
|
"Logging": {
|
||||||
"LogLevel": {
|
"LogLevel": {
|
||||||
"Default": "Information",
|
"Default": "Information",
|
||||||
"Microsoft.AspNetCore": "Warning"
|
"Microsoft.AspNetCore": "Warning"
|
||||||
}
|
|
||||||
},
|
|
||||||
"AllowedHosts": "*",
|
|
||||||
"ConnectionStrings": {
|
|
||||||
"PostgreSQL": "Host=postgres;Port=5432;Database=jobot;Username=postgres;Password=LocalDbPass"
|
|
||||||
},
|
|
||||||
"HeadHunter": {
|
|
||||||
"Links": {
|
|
||||||
"AuthLink": "https://hh.ru/oauth/authorize?response_type=code&client_id={0}&redirect_uri={1}",
|
|
||||||
"HookDomain": "jobot.lisoveliy.su",
|
|
||||||
"HookRoute": "/auth",
|
|
||||||
"HeadHunterApiDomain": "api.hh.ru",
|
|
||||||
"HeadHunterTokenRoute": "/token"
|
|
||||||
},
|
|
||||||
"ClientId": "",
|
|
||||||
"Secret": ""
|
|
||||||
},
|
|
||||||
"Kestrel": {
|
|
||||||
"Endpoints": {
|
|
||||||
"gRPC": {
|
|
||||||
"Url": "http://*:5001",
|
|
||||||
"Protocols": "Http2"
|
|
||||||
},
|
|
||||||
"REST": {
|
|
||||||
"Url": "http://*:5000",
|
|
||||||
"Protocols": "Http1"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
"AllowedHosts": "*",
|
||||||
|
"ConnectionStrings": {
|
||||||
|
"PostgreSQL": "Host=postgres;Port=5432;Database=jobot;Username=postgres;Password=LocalDbPass"
|
||||||
|
},
|
||||||
|
"HeadHunter": {
|
||||||
|
"Links": {
|
||||||
|
"AuthLink": "https://hh.ru/oauth/authorize?response_type=code&client_id={0}&redirect_uri={1}",
|
||||||
|
"HookDomain": "jobot.lisoveliy.su",
|
||||||
|
"HookRoute": "/auth",
|
||||||
|
"HeadHunterApiDomain": "api.hh.ru",
|
||||||
|
"HeadHunterTokenRoute": "/token"
|
||||||
|
},
|
||||||
|
"ClientId": "",
|
||||||
|
"Secret": ""
|
||||||
|
},
|
||||||
|
"Kestrel": {
|
||||||
|
"Endpoints": {
|
||||||
|
"gRPC": {
|
||||||
|
"Url": "http://*:5001",
|
||||||
|
"Protocols": "Http2"
|
||||||
|
},
|
||||||
|
"REST": {
|
||||||
|
"Url": "http://*:5000",
|
||||||
|
"Protocols": "Http1"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
@ -1,7 +1,8 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
|
||||||
<root>
|
<root>
|
||||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata" id="root"
|
||||||
|
xmlns="">
|
||||||
<xsd:element name="root" msdata:IsDataSet="true">
|
<xsd:element name="root" msdata:IsDataSet="true">
|
||||||
|
|
||||||
</xsd:element>
|
</xsd:element>
|
||||||
@ -13,10 +14,14 @@
|
|||||||
<value>1.3</value>
|
<value>1.3</value>
|
||||||
</resheader>
|
</resheader>
|
||||||
<resheader name="reader">
|
<resheader name="reader">
|
||||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral,
|
||||||
|
PublicKeyToken=b77a5c561934e089
|
||||||
|
</value>
|
||||||
</resheader>
|
</resheader>
|
||||||
<resheader name="writer">
|
<resheader name="writer">
|
||||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral,
|
||||||
|
PublicKeyToken=b77a5c561934e089
|
||||||
|
</value>
|
||||||
</resheader>
|
</resheader>
|
||||||
<data name="EULAAgrement" xml:space="preserve">
|
<data name="EULAAgrement" xml:space="preserve">
|
||||||
<value>Соглашаюсь с условиями использования ✅</value>
|
<value>Соглашаюсь с условиями использования ✅</value>
|
||||||
|
@ -1,9 +1,7 @@
|
|||||||
using JOBot.Proto;
|
using JOBot.Proto;
|
||||||
using JOBot.TClient.Infrastructure.Attributes.Authorization;
|
using JOBot.TClient.Infrastructure.Attributes.Authorization;
|
||||||
using JOBot.TClient.Services;
|
|
||||||
using JOBot.TClient.Statements;
|
using JOBot.TClient.Statements;
|
||||||
using Telegram.Bot.Types;
|
using Telegram.Bot.Types;
|
||||||
using Telegram.Bot.Types.Enums;
|
|
||||||
|
|
||||||
namespace JOBot.TClient.Commands.Buttons;
|
namespace JOBot.TClient.Commands.Buttons;
|
||||||
|
|
||||||
|
@ -1,17 +1,18 @@
|
|||||||
using JOBot.Proto;
|
using JOBot.Proto;
|
||||||
using Telegram.Bot;
|
|
||||||
using Telegram.Bot.Types;
|
using Telegram.Bot.Types;
|
||||||
|
|
||||||
namespace JOBot.TClient.Commands;
|
namespace JOBot.TClient.Commands;
|
||||||
|
|
||||||
public interface IAuthorizedTelegramCommand : ITelegramCommand
|
public interface IAuthorizedTelegramCommand : ITelegramCommand
|
||||||
{
|
{
|
||||||
public Task ExecuteAsync(Update update, GetUserResponse user, CancellationToken ct);
|
/// <exception cref="UnauthorizedAccessException">
|
||||||
|
/// Throws if you try to use ITelegramCommand.ExecuteAsync
|
||||||
/// <exception cref="UnauthorizedAccessException">Throws if you try to use ITelegramCommand.ExecuteAsync
|
/// instead of IAuthorizedTelegramCommand.ExecuteAsync
|
||||||
/// instead of IAuthorizedTelegramCommand.ExecuteAsync</exception>
|
/// </exception>
|
||||||
Task ITelegramCommand.ExecuteAsync(Update update, CancellationToken ct)
|
Task ITelegramCommand.ExecuteAsync(Update update, CancellationToken ct)
|
||||||
{
|
{
|
||||||
throw new UnauthorizedAccessException("You do not have permission to access this command.");
|
throw new UnauthorizedAccessException("You do not have permission to access this command.");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public Task ExecuteAsync(Update update, GetUserResponse user, CancellationToken ct);
|
||||||
}
|
}
|
@ -5,10 +5,10 @@ using JOBot.TClient.Infrastructure.Attributes.Authorization;
|
|||||||
using JOBot.TClient.Infrastructure.Extensions;
|
using JOBot.TClient.Infrastructure.Extensions;
|
||||||
using JOBot.TClient.Services;
|
using JOBot.TClient.Services;
|
||||||
using Microsoft.Extensions.DependencyInjection;
|
using Microsoft.Extensions.DependencyInjection;
|
||||||
|
using Microsoft.Extensions.Hosting;
|
||||||
using Microsoft.Extensions.Logging;
|
using Microsoft.Extensions.Logging;
|
||||||
using Telegram.Bot;
|
using Telegram.Bot;
|
||||||
using Telegram.Bot.Types;
|
using Telegram.Bot.Types;
|
||||||
using Microsoft.Extensions.Hosting;
|
|
||||||
|
|
||||||
namespace JOBot.TClient.Core.HostedServices;
|
namespace JOBot.TClient.Core.HostedServices;
|
||||||
|
|
||||||
@ -22,8 +22,8 @@ public sealed class BotBackgroundService(
|
|||||||
protected override Task ExecuteAsync(CancellationToken stoppingToken)
|
protected override Task ExecuteAsync(CancellationToken stoppingToken)
|
||||||
{
|
{
|
||||||
botClient.StartReceiving(
|
botClient.StartReceiving(
|
||||||
updateHandler: HandleUpdateAsync,
|
HandleUpdateAsync,
|
||||||
errorHandler: HandleErrorAsync,
|
HandleErrorAsync,
|
||||||
cancellationToken: stoppingToken);
|
cancellationToken: stoppingToken);
|
||||||
|
|
||||||
return Task.CompletedTask;
|
return Task.CompletedTask;
|
||||||
@ -40,7 +40,7 @@ public sealed class BotBackgroundService(
|
|||||||
["/info"] = scope.ServiceProvider.GetRequiredService<InfoCommand>(),
|
["/info"] = scope.ServiceProvider.GetRequiredService<InfoCommand>(),
|
||||||
|
|
||||||
//Buttons
|
//Buttons
|
||||||
[ButtonResource.EULAAgrement] = scope.ServiceProvider.GetRequiredService<EulaAgreementButtonCommand>(),
|
[ButtonResource.EULAAgrement] = scope.ServiceProvider.GetRequiredService<EulaAgreementButtonCommand>()
|
||||||
};
|
};
|
||||||
|
|
||||||
if (update.Message is { Text: { } text, From: not null })
|
if (update.Message is { Text: { } text, From: not null })
|
||||||
@ -69,7 +69,10 @@ public sealed class BotBackgroundService(
|
|||||||
|
|
||||||
await authorizedTelegramCommand.ExecuteAsync(update, user, ct);
|
await authorizedTelegramCommand.ExecuteAsync(update, user, ct);
|
||||||
}
|
}
|
||||||
else await command.ExecuteAsync(update, ct);
|
else
|
||||||
|
{
|
||||||
|
await command.ExecuteAsync(update, ct);
|
||||||
|
}
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -20,29 +20,37 @@ public static class DependencyInjection
|
|||||||
services.AddSingleton(config);
|
services.AddSingleton(config);
|
||||||
|
|
||||||
services.AddScoped<ChannelBase, GrpcChannel>(_ => GrpcChannel.ForAddress(config.GetValue<string>("BackendHost")
|
services.AddScoped<ChannelBase, GrpcChannel>(_ => GrpcChannel.ForAddress(config.GetValue<string>("BackendHost")
|
||||||
?? throw new MissingFieldException("Host is not defined")));
|
?? throw new MissingFieldException("Host is not defined")));
|
||||||
|
|
||||||
#region Commands
|
#region Commands
|
||||||
|
|
||||||
services.AddScoped<StartCommand>();
|
services.AddScoped<StartCommand>();
|
||||||
services.AddScoped<MenuCommand>();
|
services.AddScoped<MenuCommand>();
|
||||||
services.AddScoped<InfoCommand>();
|
services.AddScoped<InfoCommand>();
|
||||||
|
|
||||||
//buttons
|
//buttons
|
||||||
services.AddScoped<EulaAgreementButtonCommand>();
|
services.AddScoped<EulaAgreementButtonCommand>();
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
#region gRPC Clients
|
#region gRPC Clients
|
||||||
|
|
||||||
services.AddGrpcClient<User.UserClient>(o => o.Address = new Uri("http://backend:5001"));
|
services.AddGrpcClient<User.UserClient>(o => o.Address = new Uri("http://backend:5001"));
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
#region Services
|
#region Services
|
||||||
|
|
||||||
services.AddSingleton<UserService>();
|
services.AddSingleton<UserService>();
|
||||||
services.AddScoped<PrepareUserService>();
|
services.AddScoped<PrepareUserService>();
|
||||||
services.AddScoped<MenuService>();
|
services.AddScoped<MenuService>();
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
#region States
|
#region States
|
||||||
|
|
||||||
services.AddScoped<PrepareUserState>();
|
services.AddScoped<PrepareUserState>();
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
// Bot service
|
// Bot service
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
namespace JOBot.TClient.Infrastructure.Attributes.Authorization;
|
namespace JOBot.TClient.Infrastructure.Attributes.Authorization;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
///Атрибут допуска к команде пользователя не завершившего стадию PrepareUser
|
/// Атрибут допуска к команде пользователя не завершившего стадию PrepareUser
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[AttributeUsage(AttributeTargets.Method | AttributeTargets.Class)]
|
[AttributeUsage(AttributeTargets.Method | AttributeTargets.Class)]
|
||||||
public class AcceptNotPreparedAttribute : Attribute;
|
public class AcceptNotPreparedAttribute : Attribute;
|
@ -4,14 +4,14 @@ using Telegram.Bot.Types;
|
|||||||
namespace JOBot.TClient.Infrastructure.Exceptions;
|
namespace JOBot.TClient.Infrastructure.Exceptions;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Exception for fallback
|
/// Exception for fallback
|
||||||
/// WARNING: Don't create new exception without throwing it
|
/// WARNING: Don't create new exception without throwing it
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class FallbackException : Exception
|
public class FallbackException : Exception
|
||||||
{
|
{
|
||||||
public FallbackException(string message, Message botMessage, ITelegramBotClient botClient) : base(message)
|
public FallbackException(string message, Message botMessage, ITelegramBotClient botClient) : base(message)
|
||||||
{
|
{
|
||||||
botClient.SendMessage(chatId: botMessage.Chat.Id,
|
botClient.SendMessage(botMessage.Chat.Id,
|
||||||
TextResource.FallbackMessage);
|
TextResource.FallbackMessage);
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -4,6 +4,9 @@ namespace JOBot.TClient.Infrastructure.Extensions;
|
|||||||
|
|
||||||
public static class GRpcModelsExtensions
|
public static class GRpcModelsExtensions
|
||||||
{
|
{
|
||||||
public static bool IsPrepared(this GetUserResponse user) => user is { Eula: true, IsLogged: true } &&
|
public static bool IsPrepared(this GetUserResponse user)
|
||||||
!string.IsNullOrEmpty(user.CVUrl);
|
{
|
||||||
|
return user is { Eula: true, IsLogged: true } &&
|
||||||
|
!string.IsNullOrEmpty(user.CVUrl);
|
||||||
|
}
|
||||||
}
|
}
|
@ -20,7 +20,7 @@
|
|||||||
<PackageReference Include="Microsoft.Extensions.Configuration.Json" Version="9.0.4"/>
|
<PackageReference Include="Microsoft.Extensions.Configuration.Json" Version="9.0.4"/>
|
||||||
<PackageReference Include="Microsoft.Extensions.DependencyInjection" Version="9.0.4"/>
|
<PackageReference Include="Microsoft.Extensions.DependencyInjection" Version="9.0.4"/>
|
||||||
<PackageReference Include="Microsoft.Extensions.Hosting" Version="9.0.4"/>
|
<PackageReference Include="Microsoft.Extensions.Hosting" Version="9.0.4"/>
|
||||||
<PackageReference Include="RabbitMQ.Client" Version="7.1.2" />
|
<PackageReference Include="RabbitMQ.Client" Version="7.1.2"/>
|
||||||
<PackageReference Include="Telegram.Bot" Version="22.5.1"/>
|
<PackageReference Include="Telegram.Bot" Version="22.5.1"/>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
@ -59,9 +59,9 @@
|
|||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Content Include="appsettings.json">
|
<Content Include="appsettings.json">
|
||||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||||
</Content>
|
</Content>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
</Project>
|
</Project>
|
||||||
|
@ -6,7 +6,6 @@ var host = Host.CreateDefaultBuilder(args)
|
|||||||
{
|
{
|
||||||
// Настройка DI
|
// Настройка DI
|
||||||
services.ConfigureServices(context.Configuration);
|
services.ConfigureServices(context.Configuration);
|
||||||
|
|
||||||
})
|
})
|
||||||
.Build();
|
.Build();
|
||||||
|
|
||||||
|
@ -1,6 +1,5 @@
|
|||||||
using Telegram.Bot;
|
using Telegram.Bot;
|
||||||
using Telegram.Bot.Types;
|
using Telegram.Bot.Types;
|
||||||
using User = JOBot.Proto.User;
|
|
||||||
|
|
||||||
namespace JOBot.TClient.Services;
|
namespace JOBot.TClient.Services;
|
||||||
|
|
||||||
@ -10,6 +9,6 @@ public class MenuService(ITelegramBotClient bot)
|
|||||||
{
|
{
|
||||||
ArgumentNullException.ThrowIfNull(update.Message?.From);
|
ArgumentNullException.ThrowIfNull(update.Message?.From);
|
||||||
|
|
||||||
await bot.SendMessage(update.Message.From.Id,"PrepareUser stage is done.", cancellationToken: ct);
|
await bot.SendMessage(update.Message.From.Id, "PrepareUser stage is done.", cancellationToken: ct);
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -12,7 +12,7 @@ public class PrepareUserService(ITelegramBotClient bot, User.UserClient userClie
|
|||||||
private readonly User.UserClient _userClient = userClient;
|
private readonly User.UserClient _userClient = userClient;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Get or register user on system
|
/// Get or register user on system
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="update">Telegram Update object</param>
|
/// <param name="update">Telegram Update object</param>
|
||||||
/// <param name="ct">Cancellation Token</param>
|
/// <param name="ct">Cancellation Token</param>
|
||||||
@ -26,21 +26,21 @@ public class PrepareUserService(ITelegramBotClient bot, User.UserClient userClie
|
|||||||
var result = await _userClient.RegisterAsync(new RegisterRequest
|
var result = await _userClient.RegisterAsync(new RegisterRequest
|
||||||
{
|
{
|
||||||
UserId = update.Message.From.Id,
|
UserId = update.Message.From.Id,
|
||||||
Username = update.Message.From.Username,
|
Username = update.Message.From.Username
|
||||||
});
|
});
|
||||||
|
|
||||||
if (!result.Success)
|
if (!result.Success)
|
||||||
{
|
{
|
||||||
await _bot.SendMessage(chatId: update.Message.Chat.Id,
|
await _bot.SendMessage(update.Message.Chat.Id,
|
||||||
TextResource.FallbackMessage,
|
TextResource.FallbackMessage,
|
||||||
cancellationToken: ct);
|
cancellationToken: ct);
|
||||||
|
|
||||||
throw new FallbackException(TextResource.FallbackMessage, update.Message, _bot);
|
throw new FallbackException(TextResource.FallbackMessage, update.Message, _bot);
|
||||||
}
|
}
|
||||||
|
|
||||||
var user = await _userClient.GetUserAsync(new GetUserRequest()
|
var user = await _userClient.GetUserAsync(new GetUserRequest
|
||||||
{
|
{
|
||||||
UserId = update.Message.From.Id,
|
UserId = update.Message.From.Id
|
||||||
});
|
});
|
||||||
|
|
||||||
if (user == null)
|
if (user == null)
|
||||||
@ -50,7 +50,7 @@ public class PrepareUserService(ITelegramBotClient bot, User.UserClient userClie
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Get Eula Agreement from user
|
/// Get Eula Agreement from user
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="update">Telegram Update object</param>
|
/// <param name="update">Telegram Update object</param>
|
||||||
/// <param name="ct">Cancellation Token</param>
|
/// <param name="ct">Cancellation Token</param>
|
||||||
@ -66,7 +66,7 @@ public class PrepareUserService(ITelegramBotClient bot, User.UserClient userClie
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Accept EULA for user
|
/// Accept EULA for user
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="update">Telegram update object</param>
|
/// <param name="update">Telegram update object</param>
|
||||||
/// <param name="ct">Cancellation Token</param>
|
/// <param name="ct">Cancellation Token</param>
|
||||||
@ -74,10 +74,10 @@ public class PrepareUserService(ITelegramBotClient bot, User.UserClient userClie
|
|||||||
public async Task AcceptEula(Update update, CancellationToken ct = default)
|
public async Task AcceptEula(Update update, CancellationToken ct = default)
|
||||||
{
|
{
|
||||||
ArgumentNullException.ThrowIfNull(update.Message?.From);
|
ArgumentNullException.ThrowIfNull(update.Message?.From);
|
||||||
var result = await _userClient.AcceptEulaAsync(new()
|
var result = await _userClient.AcceptEulaAsync(new AcceptEulaRequest
|
||||||
{
|
{
|
||||||
EulaAccepted = true,
|
EulaAccepted = true,
|
||||||
UserId = update.Message.From.Id,
|
UserId = update.Message.From.Id
|
||||||
});
|
});
|
||||||
|
|
||||||
if (!result.Success)
|
if (!result.Success)
|
||||||
@ -88,7 +88,7 @@ public class PrepareUserService(ITelegramBotClient bot, User.UserClient userClie
|
|||||||
{
|
{
|
||||||
ArgumentNullException.ThrowIfNull(update.Message?.From);
|
ArgumentNullException.ThrowIfNull(update.Message?.From);
|
||||||
|
|
||||||
var url = await _userClient.GetHeadHunterAuthHookAsync(new GetHeadHunterAuthHookRequest()
|
var url = await _userClient.GetHeadHunterAuthHookAsync(new GetHeadHunterAuthHookRequest
|
||||||
{
|
{
|
||||||
UserId = update.Message.From.Id
|
UserId = update.Message.From.Id
|
||||||
});
|
});
|
||||||
@ -103,6 +103,7 @@ public class PrepareUserService(ITelegramBotClient bot, User.UserClient userClie
|
|||||||
{
|
{
|
||||||
ArgumentNullException.ThrowIfNull(update.Message?.From);
|
ArgumentNullException.ThrowIfNull(update.Message?.From);
|
||||||
|
|
||||||
await _bot.SendMessage(update.Message.From.Id, "Давайте выберем одно из доступных резюме:", cancellationToken: ct); //TODO: https://git.lisoveliy.su/Lisoveliy/JOBot/issues/9
|
await _bot.SendMessage(update.Message.From.Id, "Давайте выберем одно из доступных резюме:",
|
||||||
|
cancellationToken: ct); //TODO: https://git.lisoveliy.su/Lisoveliy/JOBot/issues/9
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -10,7 +10,7 @@ namespace JOBot.TClient.Services;
|
|||||||
public class UserService(ITelegramBotClient bot, User.UserClient userClient)
|
public class UserService(ITelegramBotClient bot, User.UserClient userClient)
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Get user
|
/// Get user
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="update">Telegram Update object</param>
|
/// <param name="update">Telegram Update object</param>
|
||||||
/// <param name="ct">Cancellation Token</param>
|
/// <param name="ct">Cancellation Token</param>
|
||||||
@ -26,7 +26,7 @@ public class UserService(ITelegramBotClient bot, User.UserClient userClient)
|
|||||||
{
|
{
|
||||||
user = await userClient.GetUserAsync(new GetUserRequest() //Получаем пользователя
|
user = await userClient.GetUserAsync(new GetUserRequest() //Получаем пользователя
|
||||||
{
|
{
|
||||||
UserId = update.Message.From.Id,
|
UserId = update.Message.From.Id
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
catch (RpcException e) //Пользователь не найден?
|
catch (RpcException e) //Пользователь не найден?
|
||||||
@ -36,6 +36,7 @@ public class UserService(ITelegramBotClient bot, User.UserClient userClient)
|
|||||||
|
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
return user;
|
return user;
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -7,7 +7,7 @@ namespace JOBot.TClient.Statements;
|
|||||||
public class PrepareUserState(PrepareUserService prepareUserService, MenuService menuService)
|
public class PrepareUserState(PrepareUserService prepareUserService, MenuService menuService)
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Try to prepare user if is not registered
|
/// Try to prepare user if is not registered
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="update">Update telegram object</param>
|
/// <param name="update">Update telegram object</param>
|
||||||
/// <param name="ct">Cancellation token</param>
|
/// <param name="ct">Cancellation token</param>
|
||||||
@ -25,19 +25,19 @@ public class PrepareUserState(PrepareUserService prepareUserService, MenuService
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Signal for accepted eula
|
/// Signal for accepted eula
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="user"></param>
|
/// <param name="user"></param>
|
||||||
/// <param name="update"></param>
|
/// <param name="update"></param>
|
||||||
/// <param name="ct"></param>
|
/// <param name="ct"></param>
|
||||||
public async Task AcceptEula(GetUserResponse user, Update update, CancellationToken ct = default)
|
public async Task AcceptEula(GetUserResponse user, Update update, CancellationToken ct = default)
|
||||||
{
|
{
|
||||||
await prepareUserService.AcceptEula(update, ct: ct);
|
await prepareUserService.AcceptEula(update, ct);
|
||||||
await OnUserEulaValidStage(user, update, ct);
|
await OnUserEulaValidStage(user, update, ct);
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Check user logged
|
/// Check user logged
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="user"></param>
|
/// <param name="user"></param>
|
||||||
/// <param name="update"></param>
|
/// <param name="update"></param>
|
||||||
@ -49,21 +49,19 @@ public class PrepareUserState(PrepareUserService prepareUserService, MenuService
|
|||||||
await prepareUserService.Auth(update, ct);
|
await prepareUserService.Auth(update, ct);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
await OnAuthStage(user, update, ct);
|
await OnAuthStage(user, update, ct);
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Check user selected CV
|
/// Check user selected CV
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="user"></param>
|
/// <param name="user"></param>
|
||||||
/// <param name="update"></param>
|
/// <param name="update"></param>
|
||||||
/// <param name="ct"></param>
|
/// <param name="ct"></param>
|
||||||
private async Task OnAuthStage(GetUserResponse user, Update update, CancellationToken ct = default)
|
private async Task OnAuthStage(GetUserResponse user, Update update, CancellationToken ct = default)
|
||||||
{
|
{
|
||||||
if (string.IsNullOrEmpty(user.CVUrl))
|
if (string.IsNullOrEmpty(user.CVUrl)) await prepareUserService.SelectCv(update, ct);
|
||||||
{
|
|
||||||
await prepareUserService.SelectCv(update, ct);
|
|
||||||
}
|
|
||||||
await menuService.RenderMenu(update, ct); //boilerplate
|
await menuService.RenderMenu(update, ct); //boilerplate
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -1,7 +1,8 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
|
||||||
<root>
|
<root>
|
||||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata" id="root"
|
||||||
|
xmlns="">
|
||||||
<xsd:element name="root" msdata:IsDataSet="true">
|
<xsd:element name="root" msdata:IsDataSet="true">
|
||||||
|
|
||||||
</xsd:element>
|
</xsd:element>
|
||||||
@ -13,10 +14,14 @@
|
|||||||
<value>1.3</value>
|
<value>1.3</value>
|
||||||
</resheader>
|
</resheader>
|
||||||
<resheader name="reader">
|
<resheader name="reader">
|
||||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral,
|
||||||
|
PublicKeyToken=b77a5c561934e089
|
||||||
|
</value>
|
||||||
</resheader>
|
</resheader>
|
||||||
<resheader name="writer">
|
<resheader name="writer">
|
||||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral,
|
||||||
|
PublicKeyToken=b77a5c561934e089
|
||||||
|
</value>
|
||||||
</resheader>
|
</resheader>
|
||||||
<data name="EULA" xml:space="preserve">
|
<data name="EULA" xml:space="preserve">
|
||||||
<value>Продолжая, вы принимаете политику конфиденциальности и правила сервиса
|
<value>Продолжая, вы принимаете политику конфиденциальности и правила сервиса
|
||||||
|
20
README.md
20
README.md
@ -5,7 +5,7 @@ Telegram-бот для автоматизации поиска работы че
|
|||||||
|
|
||||||
## 🔥 Возможности
|
## 🔥 Возможности
|
||||||
|
|
||||||
Привяжите аккаунт HeadHunter для доступа к резюме и вакансиям.
|
Привяжите аккаунт HeadHunter для доступа к резюме и вакансиям.
|
||||||
|
|
||||||
- **Отклик по предпочтениям**
|
- **Отклик по предпочтениям**
|
||||||
|
|
||||||
@ -31,30 +31,36 @@ Telegram-бот для автоматизации поиска работы че
|
|||||||
## 🚀 Запуск
|
## 🚀 Запуск
|
||||||
|
|
||||||
### Требования
|
### Требования
|
||||||
|
|
||||||
- .NET 8 SDK
|
- .NET 8 SDK
|
||||||
- Docker (для работы с БД)
|
- Docker (для работы с БД)
|
||||||
- Аккаунт разработчика на [dev.hh.ru](https://dev.hh.ru)
|
- Аккаунт разработчика на [dev.hh.ru](https://dev.hh.ru)
|
||||||
|
|
||||||
### 1. Настройка конфигурации
|
### 1. Настройка конфигурации
|
||||||
|
|
||||||
Создайте `appsettings.json` в `JOBot.TClient` на основе `appsettings.Example.json`
|
Создайте `appsettings.json` в `JOBot.TClient` на основе `appsettings.Example.json`
|
||||||
|
|
||||||
### 2. Запуск через Docker
|
### 2. Запуск через Docker
|
||||||
|
|
||||||
```
|
```
|
||||||
docker-compose up -d --build
|
docker-compose up -d --build
|
||||||
```
|
```
|
||||||
|
|
||||||
## 📌 Команды бота
|
## 📌 Команды бота
|
||||||
|Команда|Описание|
|
|
||||||
|-------|--------|
|
| Команда | Описание |
|
||||||
|/start |Начало работы|
|
|---------|----------------------------------------------|
|
||||||
|/menu|Настройка откликов и резюме по предпочтениям|
|
| /start | Начало работы |
|
||||||
|/info|Информация о боте|
|
| /menu | Настройка откликов и резюме по предпочтениям |
|
||||||
|
| /info | Информация о боте |
|
||||||
|
|
||||||
📄 Лицензия
|
📄 Лицензия
|
||||||
MIT License. Подробнее в файле LICENSE.
|
MIT License. Подробнее в файле LICENSE.
|
||||||
|
|
||||||
## Отказ от ответственности
|
## Отказ от ответственности
|
||||||
|
|
||||||
Продолжая, вы принимаете [политику конфиденциальности](https://hh.ru/article/personal_data?backurl=%2F&role=applicant) и [правила сервиса](https://hh.ru/account/agreement?backurl=%2Faccount%2Fsignup%3Fbackurl%3D%252F%26role%3Dapplicant&role=applicant) hh.ru
|
Продолжая, вы принимаете [политику конфиденциальности](https://hh.ru/article/personal_data?backurl=%2F&role=applicant)
|
||||||
|
и [правила сервиса](https://hh.ru/account/agreement?backurl=%2Faccount%2Fsignup%3Fbackurl%3D%252F%26role%3Dapplicant&role=applicant)
|
||||||
|
hh.ru
|
||||||
|
|
||||||
Этот сервис никак не связан с HeadHunter™ (далее hh.ru), не выдаёт себя за hh.ru и не является hh.ru
|
Этот сервис никак не связан с HeadHunter™ (далее hh.ru), не выдаёт себя за hh.ru и не является hh.ru
|
Loading…
x
Reference in New Issue
Block a user