#pragma once

#include <string>
#include <cstring>
#include <map>

#include <string.h>
#include <curl/curl.h> 
#include <fstream>
#include "base64.h"
#include "json.h"
#include <vector>
#include <iostream>

class HWOcrClientToken {
private:

	std::string m_token;

	std::string m_username;

	std::string m_password;

	std::string m_region;

	std::string m_type;

	std::string m_domainname;

public:
	HWOcrClientToken();
	virtual ~HWOcrClientToken();
	void init(std::string domainname, std::string username, std::string password, std::string region = "cn-north-4");
	void get_token();
	std::string ocr_post(std::string imPath, std::string reqUrl, Json::Value jsonOption);
};