Futibatinib and Pembrolizumab for Treatment of Advanced or Metastatic FGF19 Positive BCLC Stage A, B, or C Liver Cancer

This phase II trial studies the effect of futibatinib and pembrolizumab in treating patients with FGF19 positive BCLC stage A, B, or C liver cancer that has spread to other parts of the body (advanced or metastatic). Futibatinib may stop the growth of cancer cells by blocking some of the enzymes needed for cell growth. Immunotherapy with monoclonal antibodies, such as pembrolizumab, may help the body's immune system attack the cancer, and may interfere with the ability of tumor cells to grow and spread. Giving futibatinib and pembrolizumab may help treat patients with FGF19 positive liver cancer.

PRIMARY OBJECTIVE:

I. Determine the efficacy of combination of futibatinib and pembrolizumab in patients with advanced hepatocellular carcinoma (HCC) and high FGF19 expression who has received at least one line of therapy using progression free survival (PFS) at 6 months.

SECONDARY OBJECTIVES:

I. Assess the safety and tolerability of futibatinib and pembrolizumab combination through adverse event monitoring.

II. Determine the overall objective response rate (ORR) and overall survival (OS) of patients with advanced HCC treated with futibatinib and pembrolizumab combination.

III. Assess change in overall health-related quality of life, as measured by the global health domain of the European Organization for Research and Treatment of Cancer Quality of Life Questionnaire (EORTC-QLQ-C30) between baseline and at time of first-restaging scan.

EXPLORATORY OBJECTIVES:

I. To evaluate the prognostic effect of baseline number of circulating tumor cells (CTCs).

II. To determine whether the change in number of CTCs post 2 months of treatment from baseline is associated with PFS and OS.

III. To evaluate the prognostic effect of baseline circulating cell-free deoxyribonucleic acid (cfDNA).

IV. To determine whether the change in cfDNA at 2 months of treatment from baseline is associated with PFS and OS.

V. To correlate drug response in patient derived organoids with clinical response and characterize the tumor microenvironment.

OUTLINE:

Patients receive futibatinib orally (PO) once daily (QD) on days 1-21 for cycles 1-9, and days 1-42 for subsequent cycles and pembrolizumab intravenously (IV) over 30 minutes on day 1. Cycles repeat every 21 days for cycles 1-9 and every 42 days for subsequent cycles for up to 2 years in the absence of disease progression or unacceptable toxicity.

After completing study treatment, patients are followed up at 30 days, every 9 weeks for up to 18 months, and then every 6 months for up to 5 years.

Eligibility Criteria:
Inclusion Criteria:

* Age \>= 18 years
* Adequate tissue for FGF19 testing by ribonucleic acid (mRNA) or immunohistochemistry (IHC)
* Disease characteristics:

  * Radiologically or pathologically confirmed hepatocellular carcinoma (HCC) that is not eligible for curative resection, transplantation, or ablative therapies
  * NOTE: Prior radiation, chemoembolization, radioembolization, or other local ablative therapies or hepatic resection are permitted
* Measurable disease by any imaging modality as defined by Response Evaluation Criteria in Solid Tumors (RECIST) 1.1 criteria in at least one site not previously treated with radiation or liver directed therapy (including bland, chemo- or radio-embolization, or ablation)

  * NOTE: Tumor lesions in a previously irradiated area are not considered measurable disease; disease that is measurable by physical examination only is not eligible
* Eastern Cooperative Oncology Group (ECOG) performance status (PS) 0, 1 or 2
* Absolute neutrophil count (ANC) \>= 1500/mm\^3 (=\< 15 days prior to registration)
* Hemoglobin \>= 8.0 g/dL (=\< 15 days prior to registration)
* Platelet count \>= 75,000/mm\^3 (=\< 15 days prior to registration)
* Albumin \>= 2.5 g/dL (=\< 15 days prior to registration)
* Alanine aminotransferase (ALT) and aspartate transaminase (AST) =\< 2.5 x upper limit of normal (ULN) (or =\< 5 x ULN for patients with liver metastasis) (=\< 15 days prior to registration)
* Total bilirubin =\< 2 x ULN (=\< 15 days prior to registration)
* Phosphorus =\< 1.5 x ULN (=\< 15 days prior to registration)
* Calcium =\< 1.5 x ULN (=\< 15 days prior to registration)
* Prothrombin time/international normalized ratio/activated partial thromboplastin time (PT/INR/aPTT) =\< 1.5 x ULN OR if patient is receiving anticoagulant therapy then INR or aPTT is within target range of therapy (=\< 15 days prior to registration)
* Calculated creatinine clearance \>= 40 ml/min using the Cockcroft-Gault formula (=\< 15 days prior to registration)
* Child-Pugh scores of =\< 7 (Child-Pugh A or B7)
* Barcelona Clinic Liver Cancer Stage (BCLC) stage A, B, or C
* Negative pregnancy test done =\< 7 days prior to registration, for persons of childbearing potential only
* Willing to use an adequate method of contraception from registration through 120 days after the last dose of study medication

  * NOTE: Only for a) persons of childbearing potential or b) persons able to father a child with partners of childbearing potential
* Able to swallow oral medication
* Provide written informed consent
* Willingness to provide mandatory blood specimens for correlative research
* Willingness to provide mandatory tissue specimens for correlative research
* Willingness and the ability to comply with scheduled visits (including geographical proximity), treatment plans, laboratory tests, and other study procedures
* Ability to complete questionnaires by themselves or with assistance

Exclusion Criteria:

* Known standard therapy for the patient's disease that is potentially curative or definitely capable of extending life expectancy
* Eligible for first-line treatment with IMbrave150 or STRIDE regimens
* Any of the following because this study involves an investigational agent whose genotoxic, mutagenic and teratogenic effects on the developing fetus and newborn are unknown:

  * Pregnant persons
  * Nursing persons
  * Persons of childbearing potential who are unwilling to employ adequate contraception
* Any of the following prior therapies:

  * Surgery =\< 4 weeks prior to registration
  * Radiotherapy for extended field =\< 4 weeks prior to registration or limited field radiotherapy =\< 2 weeks prior to registration
  * Systemic anticancer therapy =\< 2 weeks prior to registration

    * NOTE: Prior immunotherapy is allowed unless patient discontinued due to grade 4 adverse event (AE)
  * Live vaccine =\< 30 days prior to registration
  * Prior treatment with FGFR inhibitor
  * Received strong inhibitors and inducers and sensitive substrates of CYP3A4 =\< 2 weeks prior to registration
  * Received a drug that has not received regulatory approval for any indication as follows:

    * =\< 2 weeks prior to registration for nonmyelosuppressive agents or
    * =\< 4 weeks prior to registration for myelosuppressive agents
* History and/or current evidence of any of the following disorders:

  * Retinal or corneal disorder confirmed by retinal/corneal examination and considered clinically significant in the opinion of the Investigator
  * Pneumonitis or interstitial lung disease within =\< 3 years prior to registration
* Active central nervous system (CNS) metastasis and/or carcinomatous meningitis

  * NOTE: Patients with previously treated brain metastases that are clinically and radiologically stable (for at least 4 weeks prior to enrollment) are eligible
* Corrected QT interval using Fridericia's formula (QTcF) \> 480 msec

  * NOTE: Patients with an atrioventricular pacemaker or other condition (for example, right bundle branch block) that renders the QT measurement invalid are an exception and the criterion does not apply
* Co-morbid systemic illnesses or other severe concurrent disease which, in the judgment of the investigator, would make the patient inappropriate for entry into this study or interfere significantly with the proper assessment of safety and toxicity of the prescribed regimens
* Receiving any other investigational agent which would be considered as a treatment for the primary neoplasm
* History or risk of autoimmune disease, including, but not limited to, systemic lupus erythematosus, rheumatoid arthritis, inflammatory bowel disease, vascular thrombosis associated with antiphospholipid syndrome, Wegener's granulomatosis, Sjogren's syndrome, Guillain-Barre syndrome, multiple sclerosis, autoimmune thyroid disease, vasculitis, or glomerulonephritis. Notes:

  * Patients with a history of autoimmune hypothyroidism on a stable dose of thyroid replacement hormone are eligible.
  * Patients with controlled Type 1 diabetes mellitus on a stable insulin regimen are eligible.
  * Patients with eczema, psoriasis, lichen simplex chronicus of vitiligo with dermatologic manifestations only (e.g., patients with psoriatic arthritis would be excluded) are permitted provided that they meet the following conditions:

    * Must not have ocular manifestations
    * Rash must cover less than 10% of body surface area (BSA)
    * Disease is well controlled at baseline and only requiring low potency topical steroids (e.g., hydrocortisone 2.5%, hydrocortisone butyrate 0.1%, flucinolone 0.01%, desonide 0.05%, aclometasone dipropionate 0.05%)
    * No acute exacerbations of underlying condition within the last 12 months (not requiring psoralen plus ultraviolet A radiation \[PUVA\], methotrexate, retinoids, biologic agents, oral calcineurin inhibitors; high potency or oral steroids)
* Known active human immunodeficiency virus (HIV) infection (defined as patients who are not on anti-retroviral treatment and have detectable viral load and CD4+ \< 500/ml)

  * NOTE: HIV-positive patients who are well controlled on anti-retroviral therapy are allowed to enroll
* History and/or current evidence of any of the following disorders:

  * Non-tumor related alteration of the calcium-phosphorus homeostasis that is considered clinically significant in the opinion of the Investigator
  * Ectopic mineralization/calcification, including but not limited to soft tissue, kidneys, intestine, or myocardia and lung, considered clinically significant in the opinion of the Investigator
  * Retinal or corneal disorder confirmed by retinal/corneal examination and considered clinically significant in the opinion of the Investigator
* Uncontrolled intercurrent illness including, but not limited to:

  * Ongoing or active severe infection

    * NOTE: Must be afebrile \> 7 days to be eligible. Patient may be eligible if fever is present and infection has been ruled out or fever is related to tumor
  * Psychiatric illness/social situations that would limit compliance with study requirements
* Clinically significant or uncontrolled cardiac disease, including unstable angina, acute myocardial infarction within 6 months from day 1 of study treatment administration, New York Heart Association class III and IV congestive heart failure, and uncontrolled arrhythmia

  * NOTE: Participants with pacemaker or with atrial fibrillation and well controlled heart rate are allowed
* Other active malignancy \<6 months prior to pre-registration

  * EXCEPTIONS: Non-melanotic skin cancer, papillary thyroid cancer, or carcinoma-in-situ of the cervix, or others curatively treated and now considered to be at less than 30% risk of relapse are eligible
* Prior organ transplantation