// File: king1600[P]cordpp/src/http.cc
// Function: cordpp::RestClient::request(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, nlohmann::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::adl_serializer> const&, std::function<void (nlohmann::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::adl_serializer> const&)> const&)
void RestClient::request(const std::string &method, const std::string &endpoint,
  const std::string &audit, const Json &data, const JsonAction &action)
{
  Request request{data, method, endpoint, audit};
  RestTask task{request, action};
  if (!conn->is_connected())
    tasks.push_back(task);
  else
    perform_task(task);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x170, %rsp            # imm = 0x170
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq %r9, -0x30(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x158(%rbp)
leaq -0xa0(%rbp), %rdi
movq %rdi, -0x150(%rbp)
movq -0x28(%rbp), %rsi
callq 0x40630
leaq -0x90(%rbp), %rdi
movq %rdi, -0x148(%rbp)
movq -0x10(%rbp), %rsi
callq 0xc1f0
jmp 0x4ef7e
leaq -0x70(%rbp), %rdi
movq %rdi, -0x160(%rbp)
movq -0x18(%rbp), %rsi
callq 0xc1f0
jmp 0x4ef94
leaq -0x50(%rbp), %rdi
movq -0x20(%rbp), %rsi
callq 0xc1f0
jmp 0x4efa3
leaq -0x140(%rbp), %rdi
movq %rdi, -0x168(%rbp)
leaq -0xa0(%rbp), %rsi
callq 0x542b0
jmp 0x4efbf
leaq -0xd0(%rbp), %rdi
movq -0x30(%rbp), %rsi
callq 0x54380
jmp 0x4efd1
movq -0x158(%rbp), %rdi
addq $0x128, %rdi            # imm = 0x128
callq 0x54430
movq %rax, %rdi
callq 0x5a7b0
movb %al, -0x169(%rbp)
jmp 0x4eff4
movb -0x169(%rbp), %al
testb $0x1, %al
jne 0x4f0dc
jmp 0x4f004
movq -0x158(%rbp), %rdi
addq $0xd8, %rdi
leaq -0x140(%rbp), %rsi
callq 0x54450
jmp 0x4f020
jmp 0x4f0f3
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xa8(%rbp)
movl %eax, -0xac(%rbp)
jmp 0x4f077
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xa8(%rbp)
movl %eax, -0xac(%rbp)
jmp 0x4f06b
movq -0x160(%rbp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xa8(%rbp)
movl %eax, -0xac(%rbp)
callq 0xcfb8
movq -0x148(%rbp), %rdi
callq 0xcfb8
movq -0x150(%rbp), %rdi
callq 0x12560
jmp 0x4f120
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xa8(%rbp)
movl %eax, -0xac(%rbp)
jmp 0x4f114
movq -0x168(%rbp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xa8(%rbp)
movl %eax, -0xac(%rbp)
callq 0x1a670
jmp 0x4f114
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0xa8(%rbp)
movl %eax, -0xac(%rbp)
leaq -0x140(%rbp), %rdi
callq 0x1a640
jmp 0x4f114
movq -0x158(%rbp), %rdi
leaq -0x140(%rbp), %rsi
callq 0x4f530
jmp 0x4f0f1
jmp 0x4f0f3
leaq -0x140(%rbp), %rdi
callq 0x1a640
leaq -0xa0(%rbp), %rdi
callq 0x1a670
addq $0x170, %rsp            # imm = 0x170
popq %rbp
retq
leaq -0xa0(%rbp), %rdi
callq 0x1a670
movq -0xa8(%rbp), %rdi
callq 0xc8c0
nopl (%rax)