MateCat.Net is a wrapper made for .NET, which works with online CAT-Tool MateCat.
The official documentation of using API see here.
Installation is performed via NuGet package.
PM> Install-Package MateCat.Net
Creating new MateCat project:
using MateCat.Net.Enums;
using MateCat.Net.Models;
using System.Collections.Generic;
namespace MateCat.Net.Example
{
public class CreateProjectExample
{
private readonly MateCatApi _mateCatApi = new MateCatApi();
public Project RunCreateProjectExample()
{
List<ProjectFile> projectFiles = new List<ProjectFile> { new ProjectFile(@"C:\Temp\Example.txt") };
Project project = _mateCatApi.CreateProject(projectFiles, "TestProjectName", "en-EN", "ru-RU", SupportedSubject.Internet);
return project;
}
}
}
Changing MateCat project password:
using MateCat.Net.Models;
namespace MateCat.Net.Example
{
public class ChangeProjectPasswordExample
{
private readonly MateCatApi _mateCatApi = new MateCatApi();
public Project RunChangeProjectPasswordExample()
{
Project project = new CreateProjectExample().RunCreateProjectExample();
project = _mateCatApi.ChangeProjectPassword(project.Id, project.Password, "MY_NEW_PASSWORD");
return project;
}
}
}
Receiving MateCat project status:
using MateCat.Net.Models;
namespace MateCat.Net.Example
{
public class GetProjectStatusExample
{
private readonly MateCatApi _mateCatApi = new MateCatApi();
public ProjectStatus RunGetProjectStatusExample()
{
Project project = new CreateProjectExample().RunCreateProjectExample();
ProjectStatus projectStatus = _mateCatApi.GetProjectStatus(project.Id, project.Password);
return projectStatus;
}
}
}
This project is licensed under the MIT license.