Niraparib and TSR-042 for the Treatment of BRCA-Mutated Unresectable or Metastatic Breast, Pancreas, Ovary, Fallopian Tube, or Primary Peritoneal Cancer

This phase IB trial evaluates the effect of niraparib and TSR-042 in treating patients with BRCA-mutated breast, pancreas, ovary, fallopian tube, or primary peritoneal cancer that cannot be removed by surgery (unresectable) or has spread to other places in the body (metastatic). Niraparib is an inhibitor of PARP, an enzyme that helps repair deoxyribonucleic acid (DNA) when it becomes damaged. Blocking PARP may help keep cancer cells from repairing their damaged DNA, causing them to die. PARP inhibitors are a type of targeted therapy. Immunotherapy with monoclonal antibodies, such as TSR-042, may help the body's immune system attack the cancer, and may interfere with the ability of tumor cells to grow and spread. Giving niraparib and TSR-042 may kill more cancer cells.

OUTLINE:

Patients receive niraparib orally (PO) once daily (QD) on days 1-28 of cycle 1. Beginning cycle 2, patients receive niraparib PO QD on days 1-21 and dostarlimab intravenously (IV) over 30 minutes on day 1. Treatment repeats every 21 days for 4 cycles in the absence of disease progression or unacceptable toxicity. Beginning cycle 6, patients receive niraparib PO QD on days 1-42 and dostarlimab IV over 30 minutes on day 1. Cycles repeat every 42 days for up to 24 months in the absence of disease progression or unacceptable toxicity. Additionally, patients undergo biopsy, blood sample collection, and computed tomography (CT) or magnetic resonance imaging (MRI) throughout the study.

After completion of study treatment, patients are followed up for 30 days, every 6 months for 2 years, and then annually for up to 5 years.

Eligibility Criteria:
Inclusion Criteria:

* Participant must have breast, pancreas, ovary, fallopian tube or primary peritoneal cancer that is unresectable or metastatic, with a pathogenic mutation in BRCA1 or BRCA2 (either germline or somatic) as confirmed by next generation gene sequencing such as University of Washington (UW) OncoPlex assay or equivalent, and who have experienced progression or been intolerant to standard therapies for their disease.

  * Breast cancer patients with or without HER2+, estrogen receptor (ER)+, and/or progesterone receptor (PR)+ disease, as determined by pathological report, are allowed
* Participant must be able and willing to undergo pre-treatment and on-treatment biopsy
* Participant must have life expectancy of 4 months or greater
* Tumor must be measurable according to Response Evaluation Criteria in Solid Tumors (RECIST)1.1 criteria
* Participant must have an Eastern Cooperative Oncology Group (ECOG) performance status of =\< 1
* Participant must be \>= 18 years of age
* Patient must be able to tolerate oral medication
* Absolute neutrophil count \>= 1,500/uL
* Platelets \>= 100,000/uL
* Hemoglobin \>= 9 g/dL
* Serum creatinine =\< 1.5 x upper limit of normal (ULN) or calculated creatinine clearance \>= 60 mL/min using the Cockcroft-Gault equation
* Total bilirubin =\< 1.5 x ULN (=\< 2.0 in patients with known Gilberts syndrome) OR direct bilirubin =\< 1 x ULN
* Aspartate aminotransferase and alanine aminotransferase =\< 2.5 x ULN unless liver metastases are present, in which case they must be =\< 5 x ULN
* International normalized ratio (INR) or prothrombin time (PT) =\< 1.5 x ULN unless patient is receiving anticoagulant therapy as long as PT or partial thromboplastin (PTT) is within therapeutic range of intended use of anticoagulants. Activated partial thromboplastin time (aPTT) =\< 1.5 x ULN unless patient is receiving anticoagulant therapy as long as PT or PTT is within therapeutic range of intended use of anticoagulants
* Asymptomatic patients with stable brain metastases must have no evidence of bleeding and no need for steroids or anti-epileptic medications for at least 7 days prior to day 1
* Participants receiving corticosteroids may continue as long as their dose is stable for at least 4 weeks prior to initiating protocol therapy
* Female participant has a negative urine or serum pregnancy test within 7 days prior to taking study treatment if of childbearing potential and agrees to abstain from activities that could result in pregnancy from screening through 180 days after the last dose of study treatment or is of nonchildbearing potential. Nonchildbearing potential is defined as follows (by other than medical reasons):

  * \>= 45 years of age and has not had menses for \> 1 year
  * Patients who have been amenorrhoeic for \< 2 years without history of a hysterectomy and oophorectomy must have a follicle stimulating hormone value in the postmenopausal range upon screening evaluation
  * Post-hysterectomy, post-bilateral oophorectomy, or post-tubal ligation. Documented hysterectomy or oophorectomy must be confirmed with medical records of the actual procedure or confirmed by an ultrasound. Tubal ligation must be confirmed with medical records of the actual procedure, otherwise the patient must be willing to use 2 adequate barrier methods throughout the study, starting with the screening visit through 180 days after the last dose of study treatment. Information must be captured appropriately within the site's source documents. Note: Abstinence is acceptable if this is the established and preferred contraception for the patient
* Participant must agree to not breastfeed during the study or for 180 days after the last dose of study treatment
* Male participant agrees to use an adequate method of contraception starting with the first dose of study treatment through 180 days after the last dose of study treatment. Note: Abstinence is acceptable if this is the established and preferred contraception for the patient
* Participant must be able to understand the study procedures and agree to participate in the study by providing written informed consent
* Participant must agree to not donate blood during the study or for 90 days after the last dose of study treatment
* Prior treatment with a PARP inhibitor is allowed as long as patient has not had previous exposure to immune checkpoint inhibitor including inhibitors of PD1, PD-L1 or CTLA4
* Prior treatment with immune checkpoint inhibitor including inhibitors of PD1, PD-L1 or CTLA4 is allowed as long as patient has not had previous exposure to PARP inhibitor

Exclusion Criteria:

* Participant must not be simultaneously enrolled in any interventional clinical trial
* Participant must not have had major surgery =\< 3 weeks prior to initiating protocol therapy and participant must have recovered from any surgical effects
* Prior treatment with both PARP inhibitor and immune checkpoint inhibitor blockade either sequentially or together including inhibitors of PD1, PD-L1 or CTLA4 is not allowed. Patients may have had either PARP inhibitor or Immune checkpoint inhibitor previously but not within 3 weeks of starting treatment for prior PARP inhibitor or 12 weeks or 5x the half-life (whichever is shorter) for prior immune checkpoint inhibitors
* Participant must not have received investigational therapy =\< 4 weeks, or within a time interval less than at least 5 half-lives of the investigational agent, whichever is shorter, prior initiating protocol therapy
* Participant must not have had radiation therapy encompassing \> 20% of the bone marrow within 2 weeks; or any radiation therapy within 1 week prior to day 1 of protocol therapy
* Participant must not have a known hypersensitivity to niraparib and dostarlimab (TSR-042) components or excipients
* Participant must not have received a transfusion (platelets or red blood cells) =\< 4 weeks prior to initiating protocol therapy
* Participant must not have received colony stimulating factors (e.g., granulocyte colony-stimulating factor, granulocyte macrophage colony stimulating factor, or recombinant erythropoietin) within 4 weeks prior initiating protocol therapy
* Participant has had any known grade 3 or 4 anemia, neutropenia or thrombocytopenia due to prior chemotherapy that persisted \> 4 weeks and was related to the most recent treatment
* Participant must not have any known history of myelodysplastic syndrome (MDS) or acute myeloid leukemia (AML)
* Participant must not have a serious, uncontrolled medical disorder, nonmalignant systemic disease, or active, uncontrolled infection. Examples include, but are not limited to, uncontrolled ventricular arrhythmia, recent (within 90 days) myocardial infarction, uncontrolled major seizure disorder, unstable spinal cord compression, superior vena cava syndrome, or any psychiatric disorder that prohibits obtaining informed consent
* Participant must not have had diagnosis, detection, or treatment of another type of cancer =\< 2 years prior to initiating protocol therapy (except basal or squamous cell carcinoma of the skin and in situ cervical cancer that has been definitively treated or a BRCA-related cancer (i.e., breast, prostate, pancreas or ovarian)
* Participant must not have a known partial or complete bowel obstruction that is incompatible with oral feeding and/or absorption of oral medications
* Patient experienced \>= grade 3 immune-related adverse event (AE) with prior immunotherapy, with the exception of non-clinically significant lab abnormalities
* Participant has a diagnosis of immunodeficiency or has received systemic steroid therapy or any other form of immunosuppressive therapy within 7 days prior to initiating protocol therapy
* Participant has a known history of human immunodeficiency virus (type 1 or 2 antibodies)
* Participant has known active hepatitis B (e.g., hepatitis B surface antigen \[HBsAg\] reactive) or hepatitis C (e.g., hepatitis C virus \[HCV\] ribonucleic acid \[qualitative\] is detected)
* Participant has an active autoimmune disease that has required systemic treatment in the past 2 years (i.e., with use of disease-modifying agents, corticosteroids, or immunosuppressive drugs). Replacement therapy (e.g., thyroxine, insulin, or physiologic corticosteroid replacement therapy for adrenal or pituitary insufficiency, etc.) is not considered a form of systemic treatment
* Participant must not have a history of interstitial lung disease
* Participant has received a live vaccine within 14 days of initiating protocol therapy