Skip to content

OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub

Updated specs for FileInfo Make StorageErrorData a Data and Simplify StorageFileInfo initializer Adds the 2nd necessary query to file_info_command Update the VCR cassete for not found Update FilesInfo tests

Marcello Rochac5f88853e523
diff --git a/modules/storages/app/common/storages/peripherals/storage_interaction/one_drive/file_info_query.rb b/modules/storages/app/common/storages/peripherals/storage_interaction/one_drive/file_info_query.rb
index 4d110509cc6..b12772c1d24 100644
--- a/modules/storages/app/common/storages/peripherals/storage_interaction/one_drive/file_info_query.rb
+++ b/modules/storages/app/common/storages/peripherals/storage_interaction/one_drive/file_info_query.rb
@@ -34,7 +34,6 @@ module Storages
module OneDrive
class FileInfoQuery
FIELDS = %w[id name fileSystemInfo file folder size createdBy lastModifiedBy parentReference].freeze
- Auth = ::Storages::Peripherals::StorageInteraction::Authentication
def self.call(storage:, auth_strategy:, file_id:)
new(storage).call(auth_strategy:, file_id:)
@@ -42,50 +41,73 @@ module Storages
def initialize(storage)
@storage = storage
- @delegate = Internal::DriveItemQuery.new(storage)
+ @drive_item_query = Internal::DriveItemQuery.new(storage)
+ @error_data = StorageErrorData.new(source: self.class)
end
def call(auth_strategy:, file_id:)
if file_id.nil?
return ServiceResult.failure(
result: :error,
- errors: ::Storages::StorageError.new(code: :error,
- data: StorageErrorData.new(source: self.class),
- log_message: "File ID can not be nil")
+ errors: StorageError.new(code: :error,
+ data: @error_data, log_message: "File ID can not be nil")
)
end
- Auth[auth_strategy].call(storage: @storage) do |http|
- @delegate.call(http:, drive_item_id: file_id, fields: FIELDS).map(&storage_file_infos)
+ user_bound_result = Authentication[auth_strategy].call(storage: @storage) do |http|
+ @drive_item_query.call(http:, drive_item_id: file_id, fields: FIELDS)
+ end
+
+ user_bound_result.on_success { |sr| return ServiceResult.success(result: storage_file_infos(sr.result)) }
+ user_bound_result.on_failure do |sr|
+ return sr unless sr.result == :not_found
+
+ return admin_query(file_id)
end
end
private
- # rubocop:disable Metrics/AbcSize
- def storage_file_infos
- ->(json) do
- StorageFileInfo.new(
- status: "ok",
- status_code: 200,
- id: json[:id],
- name: json[:name],
- last_modified_at: Time.zone.parse(json.dig(:fileSystemInfo, :lastModifiedDateTime)),
- created_at: Time.zone.parse(json.dig(:fileSystemInfo, :createdDateTime)),
- mime_type: Util.mime_type(json),
- size: json[:size],
- owner_name: json.dig(:createdBy, :user, :displayName),
- owner_id: json.dig(:createdBy, :user, :id),
- trashed: false,
- last_modified_by_name: json.dig(:lastModifiedBy, :user, :displayName),
- last_modified_by_id: json.dig(:lastModifiedBy, :user, :id),
- permissions: nil,
- location: Util.extract_location(json[:parentReference], json[:name])
+ def admin_query(file_id)
+ admin_result = Authentication[userless_strategy].call(storage: @storage) do |http|
+ @drive_item_query.call(http:, drive_item_id: file_id, fields: FIELDS)
+ end
+
+ admin_result.on_success do |admin_query|
+ return ServiceResult.success(
+ result: storage_file_infos(admin_query.result, status: "forbidden", status_code: 403)
)
end
end
- # rubocop:enable Metrics/AbcSize
+ def userless_strategy = Registry.resolve("one_drive.authentication.userless").call
+
+ def storage_file_infos(json, status: "ok", status_code: 200)
+ info = StorageFileInfo.new(
+ status:,
+ status_code:,
+ id: json[:id],
+ name: json[:name],
+ mime_type: Util.mime_type(json),
+ size: json[:size],
+ owner_name: json.dig(:createdBy, :user, :displayName),
+ owner_id: json.dig(:createdBy, :user, :id),
+ trashed: false,
+ permissions: nil,
+ location: Util.extract_location(json[:parentReference], json[:name])
+ )
+
+ add_file_change_info(info, json)
+ end
+
+ def add_file_change_info(file_info, json)
+ file_info.with(
+ last_modified_at: Time.zone.parse(json.dig(:fileSystemInfo, :lastModifiedDateTime)),
+ created_at: Time.zone.parse(json.dig(:fileSystemInfo, :createdDateTime)),
+ last_modified_by_name: json.dig(:lastModifiedBy, :user, :displayName),
+ last_modified_by_id: json.dig(:lastModifiedBy, :user, :id)
+ )
+ end
end
end
end
diff --git a/modules/storages/app/common/storages/peripherals/storage_interaction/one_drive/files_info_query.rb b/modules/storages/app/common/storages/peripherals/storage_interaction/one_drive/files_info_query.rb
index 59e95c45720..2cd9ec69feb 100644
--- a/modules/storages/app/common/storages/peripherals/storage_interaction/one_drive/files_info_query.rb
+++ b/modules/storages/app/common/storages/peripherals/storage_interaction/one_drive/files_info_query.rb
@@ -44,19 +44,11 @@ module Storages
end
def call(auth_strategy:, file_ids:)
- if file_ids.nil?
- return ServiceResult.failure(
- result: :error,
- errors: ::Storages::StorageError.new(code: :error, log_message: "File IDs can not be nil")
- )
- end
-
- result = file_ids.map do |file_id|
+ result = Array(file_ids).map do |file_id|
file_info_result = FileInfoQuery.call(storage: @storage, auth_strategy:, file_id:)
- if file_info_result.failure? &&
- file_info_result.error_source.module_parent == AuthenticationStrategies
- # errors in the authentication strategies must short circuit the query and return the error
- return file_info_result
+
+ file_info_result.on_failure do |failed_result|
+ return failed_result if failed_result.error_source.module_parent == AuthenticationStrategies
end
wrap_storage_file_error(file_id, file_info_result)
@@ -68,21 +60,19 @@ module Storages
private
def wrap_storage_file_error(file_id, query_result)
- if query_result.success?
- query_result.result
- else
- status = if query_result.error_payload.instance_of?(HTTPX::ErrorResponse)
- query_result.error_payload.error
- else
- query_result.error_payload.dig(:error, :code)
- end
+ return query_result.result if query_result.success?
- StorageFileInfo.new(
- id: file_id,
- status:,
- status_code: Rack::Utils::SYMBOL_TO_STATUS_CODE[query_result.errors.code] || 500
- )
- end
+ status = if query_result.error_payload.instance_of?(HTTPX::ErrorResponse)
+ query_result.error_payload.error
+ else
+ query_result.error_payload.dig(:error, :code)
+ end
+
+ StorageFileInfo.new(
+ id: file_id,
+ status:,
+ status_code: Rack::Utils::SYMBOL_TO_STATUS_CODE[query_result.errors.code] || 500
+ )
end
end
end
diff --git a/modules/storages/app/models/storages/storage_error_data.rb b/modules/storages/app/models/storages/storage_error_data.rb
index e6e4d5f2f54..d087efd0025 100644
--- a/modules/storages/app/models/storages/storage_error_data.rb
+++ b/modules/storages/app/models/storages/storage_error_data.rb
@@ -29,12 +29,7 @@
#++
module Storages
- class StorageErrorData
- attr_reader :source, :payload
-
- def initialize(source:, payload: nil)
- @source = source
- @payload = payload
- end
+ StorageErrorData = Data.define(:source, :payload) do
+ def initialize(source:, payload: nil) = super
end
end
diff --git a/modules/storages/app/models/storages/storage_file_info.rb b/modules/storages/app/models/storages/storage_file_info.rb
index e34ec0bab9a..7020ee3a921 100644
--- a/modules/storages/app/models/storages/storage_file_info.rb
+++ b/modules/storages/app/models/storages/storage_file_info.rb
@@ -61,23 +61,7 @@ module Storages
permissions: nil,
location: nil
)
- super(
- status:,
- status_code:,
- id:,
- name:,
- last_modified_at:,
- created_at:,
- mime_type:,
- size:,
- owner_name:,
- owner_id:,
- trashed:,
- last_modified_by_name:,
- last_modified_by_id:,
- permissions:,
- location:
- )
+ super
end
def clean_location
diff --git a/modules/storages/spec/common/storages/peripherals/storage_interaction/one_drive/file_info_query_spec.rb b/modules/storages/spec/common/storages/peripherals/storage_interaction/one_drive/file_info_query_spec.rb
index 14085dea0de..b166bf4d827 100644
--- a/modules/storages/spec/common/storages/peripherals/storage_interaction/one_drive/file_info_query_spec.rb
+++ b/modules/storages/spec/common/storages/peripherals/storage_interaction/one_drive/file_info_query_spec.rb
@@ -32,15 +32,14 @@ require "spec_helper"
require_module_spec_helper
RSpec.describe Storages::Peripherals::StorageInteraction::OneDrive::FileInfoQuery, :vcr, :webmock do
- using Storages::Peripherals::ServiceResultRefinements
-
let(:user) { create(:user) }
let(:storage) { create(:sharepoint_dev_drive_storage, oauth_client_token_user: user) }
+
let(:auth_strategy) do
- Storages::Peripherals::StorageInteraction::AuthenticationStrategies::OAuthUserToken.strategy.with_user(user)
+ Storages::Peripherals::Registry["one_drive.authentication.userbound"].call(user:)
end
- subject { described_class.new(storage) }
+ subject(:file_info_query) { described_class.new(storage) }
describe "#call" do
it "responds with correct parameters" do
@@ -53,10 +52,10 @@ RSpec.describe Storages::Peripherals::StorageInteraction::OneDrive::FileInfoQuer
context "without outbound request involved" do
context "with nil" do
it "returns an error" do
- result = subject.call(auth_strategy:, file_id: nil)
+ result = file_info_query.call(auth_strategy:, file_id: nil)
expect(result).to be_failure
- expect(result.error_source).to eq(described_class)
+ expect(result.errors.data.source).to eq(described_class)
expect(result.result).to eq(:error)
end
end
@@ -67,88 +66,102 @@ RSpec.describe Storages::Peripherals::StorageInteraction::OneDrive::FileInfoQuer
context "with a file id requested", vcr: "one_drive/file_info_query_success_file" do
let(:file_id) { "01AZJL5PNCQCEBFI3N7JGZSX5AOX32Z3LA" }
- # rubocop:disable RSpec/ExampleLength
it "must return the file information when called" do
- result = subject.call(auth_strategy:, file_id:)
+ result = file_info_query.call(auth_strategy:, file_id:)
expect(result).to be_success
- result.match(
- on_success: ->(file_info) do
- expect(file_info).to be_a(Storages::StorageFileInfo)
- expect(file_info.to_h)
- .to eq({
- status: "ok",
- status_code: 200,
- id: "01AZJL5PNCQCEBFI3N7JGZSX5AOX32Z3LA",
- name: "NextcloudHub.md",
- size: 1095,
- mime_type: "application/octet-stream",
- created_at: Time.parse("2023-09-26T14:45:25Z"),
- last_modified_at: Time.parse("2023-09-26T14:46:13Z"),
- owner_name: "Eric Schubert",
- owner_id: "0a0d38a9-a59b-4245-93fa-0d2cf727f17a",
- last_modified_by_name: "Eric Schubert",
- last_modified_by_id: "0a0d38a9-a59b-4245-93fa-0d2cf727f17a",
- permissions: nil,
- trashed: false,
- location: "/Folder/Subfolder/NextcloudHub.md"
- })
- end,
- on_failure: ->(error) { fail "Expected success, got #{error}" }
- )
+ file_info = result.result
+
+ expect(file_info).to be_a(Storages::StorageFileInfo)
+ expect(file_info.to_h)
+ .to eq({
+ status: "ok",
+ status_code: 200,
+ id: "01AZJL5PNCQCEBFI3N7JGZSX5AOX32Z3LA",
+ name: "NextcloudHub.md",
+ size: 1095,
+ mime_type: "application/octet-stream",
+ created_at: Time.parse("2023-09-26T14:45:25Z"),
+ last_modified_at: Time.parse("2023-09-26T14:46:13Z"),
+ owner_name: "Eric Schubert",
+ owner_id: "0a0d38a9-a59b-4245-93fa-0d2cf727f17a",
+ last_modified_by_name: "Eric Schubert",
+ last_modified_by_id: "0a0d38a9-a59b-4245-93fa-0d2cf727f17a",
+ permissions: nil,
+ trashed: false,
+ location: "/Folder/Subfolder/NextcloudHub.md"
+ })
end
- # rubocop:enable RSpec/ExampleLength
end
context "with a folder id requested", vcr: "one_drive/file_info_query_success_folder" do
let(:file_id) { "01AZJL5PNQYF5NM3KWYNA3RJHJIB2XMMMB" }
- # rubocop:disable RSpec/ExampleLength
it "must return the file information when called" do
- result = subject.call(auth_strategy:, file_id:)
+ result = file_info_query.call(auth_strategy:, file_id:)
expect(result).to be_success
- result.match(
- on_success: ->(file_info) do
- expect(file_info).to be_a(Storages::StorageFileInfo)
- expect(file_info.to_h)
- .to eq({
- status: "ok",
- status_code: 200,
- id: "01AZJL5PNQYF5NM3KWYNA3RJHJIB2XMMMB",
- name: "Ümlæûts",
- size: 18007,
- mime_type: "application/x-op-directory",
- created_at: Time.parse("2023-10-09T15:26:32Z"),
- last_modified_at: Time.parse("2023-10-09T15:26:32Z"),
- owner_name: "Eric Schubert",
- owner_id: "0a0d38a9-a59b-4245-93fa-0d2cf727f17a",
- last_modified_by_name: "Eric Schubert",
- last_modified_by_id: "0a0d38a9-a59b-4245-93fa-0d2cf727f17a",
- permissions: nil,
- trashed: false,
- location: "/Folder/Ümlæûts"
- })
- end,
- on_failure: ->(error) { fail "Expected success, got #{error}" }
- )
+ file_info = result.result
+
+ expect(file_info).to be_a(Storages::StorageFileInfo)
+ expect(file_info.to_h)
+ .to eq({
+ status: "ok",
+ status_code: 200,
+ id: "01AZJL5PNQYF5NM3KWYNA3RJHJIB2XMMMB",
+ name: "Ümlæûts",
+ size: 20789,
+ mime_type: "application/x-op-directory",
+ created_at: Time.parse("2023-10-09T15:26:32Z"),
+ last_modified_at: Time.parse("2023-10-09T15:26:32Z"),
+ owner_name: "Eric Schubert",
+ owner_id: "0a0d38a9-a59b-4245-93fa-0d2cf727f17a",
+ last_modified_by_name: "Eric Schubert",
+ last_modified_by_id: "0a0d38a9-a59b-4245-93fa-0d2cf727f17a",
+ permissions: nil,
+ trashed: false,
+ location: "/Folder/Ümlæûts"
+ })
end
- # rubocop:enable RSpec/ExampleLength
end
end
- context "with outbound request returning not found", vcr: "one_drive/file_info_query_one_not_found" do
+ context "when the user does not have access to the file", vcr: "one_drive/file_info_query_forbidden" do
+ let(:drive_id) { "b!dmVLG22QlE2PSW0AqVB7UOhZ8n7tjkVGkgqLNnuw2ODRDvn3haLiQIhB5UYNdqMy" }
+ let(:permission_storage) { create(:sharepoint_dev_drive_storage, oauth_client_token_user: user, drive_id:) }
+
+ let(:folder) do
+ Storages::Peripherals::Registry["one_drive.commands.create_folder"]
+ .call(storage: permission_storage, folder_path: "Forbidden Folder")
+ .result
+ end
+
+ after do
+ admin_auth = Storages::Peripherals::Registry["one_drive.authentication.userless"].call
+
+ Storages::Peripherals::Registry["one_drive.commands.delete_folder"]
+ .call(storage: permission_storage, location: folder.id, auth_strategy: admin_auth)
+ end
+
+ it "returns the file information but with a forbidden status" do
+ result = described_class.call(storage: permission_storage, auth_strategy:, file_id: folder.id)
+ expect(result).to be_success
+
+ file_info = result.result
+ expect(file_info.status_code).to eq(403)
+ expect(file_info.status).to eq("forbidden")
+ end
+ end
+
+ context "with outbound request returning not found", vcr: "one_drive/file_info_query_not_found" do
let(:file_id) { "not_existent" }
it "must return not found" do
- result = subject.call(auth_strategy:, file_id:)
- expect(result).to be_failure
- expect(result.error_source).to be(Storages::Peripherals::StorageInteraction::OneDrive::Internal::DriveItemQuery)
+ result = file_info_query.call(auth_strategy:, file_id:)
- result.match(
- on_failure: ->(error) { expect(error.code).to eq(:not_found) },
- on_success: ->(file_info) { fail "Expected failure, got #{file_info}" }
- )
+ expect(result).to be_failure
+ expect(result.errors.data.source).to be(Storages::Peripherals::StorageInteraction::OneDrive::Internal::DriveItemQuery)
+ expect(result.errors.code).to eq(:not_found)
end
end
end
diff --git a/modules/storages/spec/common/storages/peripherals/storage_interaction/one_drive/files_info_query_spec.rb b/modules/storages/spec/common/storages/peripherals/storage_interaction/one_drive/files_info_query_spec.rb
index 2ec58c727af..96b450749c6 100644
--- a/modules/storages/spec/common/storages/peripherals/storage_interaction/one_drive/files_info_query_spec.rb
+++ b/modules/storages/spec/common/storages/peripherals/storage_interaction/one_drive/files_info_query_spec.rb
@@ -40,7 +40,7 @@ RSpec.describe Storages::Peripherals::StorageInteraction::OneDrive::FilesInfoQue
Storages::Peripherals::StorageInteraction::AuthenticationStrategies::OAuthUserToken.strategy.with_user(user)
end
- subject { described_class.new(storage) }
+ subject(:query) { described_class.new(storage) }
describe "#call" do
it "responds with correct parameters" do
@@ -53,7 +53,7 @@ RSpec.describe Storages::Peripherals::StorageInteraction::OneDrive::FilesInfoQue
context "without outbound request involved" do
context "with an empty array of file ids" do
it "returns an empty array" do
- result = subject.call(auth_strategy:, file_ids: [])
+ result = query.call(auth_strategy:, file_ids: [])
expect(result).to be_success
expect(result.result).to eq([])
@@ -61,11 +61,11 @@ RSpec.describe Storages::Peripherals::StorageInteraction::OneDrive::FilesInfoQue
end
context "with nil" do
- it "returns an error" do
- result = subject.call(auth_strategy:, file_ids: nil)
+ it "returns an empty array" do
+ result = query.call(auth_strategy:, file_ids: nil)
- expect(result).to be_failure
- expect(result.result).to eq(:error)
+ expect(result).to be_success
+ expect(result.result).to eq([])
end
end
end
@@ -82,7 +82,7 @@ RSpec.describe Storages::Peripherals::StorageInteraction::OneDrive::FilesInfoQue
# rubocop:disable RSpec/ExampleLength
it "must return an array of file information when called" do
- result = subject.call(auth_strategy:, file_ids:)
+ result = query.call(auth_strategy:, file_ids:)
expect(result).to be_success
result.match(
@@ -156,7 +156,7 @@ RSpec.describe Storages::Peripherals::StorageInteraction::OneDrive::FilesInfoQue
let(:file_ids) { %w[01AZJL5PJTICED3C5YSVAY6NWTBNA2XERU not_existent] }
it "must return an array of file information when called" do
- result = subject.call(auth_strategy:, file_ids:)
+ result = query.call(auth_strategy:, file_ids:)
expect(result).to be_success
result.match(
diff --git a/modules/storages/spec/support/fixtures/vcr_cassettes/one_drive/file_info_query_forbidden.yml b/modules/storages/spec/support/fixtures/vcr_cassettes/one_drive/file_info_query_forbidden.yml
new file mode 100644
index 00000000000..661aa02f4e7
--- /dev/null
+++ b/modules/storages/spec/support/fixtures/vcr_cassettes/one_drive/file_info_query_forbidden.yml
@@ -0,0 +1,354 @@
+---
+http_interactions:
+- request:
+ method: post
+ uri: https://login.microsoftonline.com/4d44bf36-9b56-45c0-8807-bbf386dd047f/oauth2/v2.0/token
+ body:
+ encoding: UTF-8
+ string: grant_type=client_credentials&scope=https%3A%2F%2Fgraph.microsoft.com%2F.default
+ headers:
+ User-Agent:
+ - Rack::OAuth2 (2.2.1)
+ Authorization:
+ - Basic <BASIC_AUTH>
+ Content-Type:
+ - application/x-www-form-urlencoded
+ Accept-Encoding:
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
+ Accept:
+ - "*/*"
+ response:
+ status:
+ code: 200
+ message: OK
+ headers:
+ Cache-Control:
+ - no-store, no-cache
+ Pragma:
+ - no-cache
+ Content-Type:
+ - application/json; charset=utf-8
+ Expires:
+ - "-1"
+ Strict-Transport-Security:
+ - max-age=31536000; includeSubDomains
+ X-Content-Type-Options:
+ - nosniff
+ P3p:
+ - CP="DSP CUR OTPi IND OTRi ONL FIN"
+ X-Ms-Request-Id:
+ - 9ccbdf3f-d9a7-45ab-b4da-b1659f74b800
+ X-Ms-Ests-Server:
+ - 2.1.17846.6 - SEC ProdSlices
+ X-Ms-Srs:
+ - 1.P
+ X-Xss-Protection:
+ - '0'
+ Set-Cookie:
+ - fpc=Aqgdg4QXwYFCsvfdSklAGxOkbDoXAQAAAKsdvN0OAAAA; expires=Sat, 25-May-2024
+ 09:47:24 GMT; path=/; secure; HttpOnly; SameSite=None
+ - stsservicecookie=estsfd; path=/; secure; samesite=none; httponly
+ - x-ms-gateway-slice=estsfd; path=/; secure; samesite=none; httponly
+ Date:
+ - Thu, 25 Apr 2024 09:47:23 GMT
+ Content-Length:
+ - '1708'
+ body:
+ encoding: UTF-8
+ string: '{"token_type":"Bearer","expires_in":3599,"ext_expires_in":3599,"access_token":"<ACCESS_TOKEN>"}'
+ recorded_at: Thu, 25 Apr 2024 09:47:24 GMT
+- request:
+ method: post
+ uri: https://graph.microsoft.com/v1.0/drives/b!dmVLG22QlE2PSW0AqVB7UOhZ8n7tjkVGkgqLNnuw2ODRDvn3haLiQIhB5UYNdqMy/root/children
+ body:
+ encoding: UTF-8
+ string: '{"name":"Forbidden Folder","folder":{},"@microsoft.graph.conflictBehavior":"fail"}'
+ headers:
+ Authorization:
+ - Bearer <BEARER TOKEN>
+ Accept:
+ - application/json
+ Content-Type:
+ - application/json
+ User-Agent:
+ - httpx.rb/1.2.4
+ Accept-Encoding:
+ - gzip, deflate
+ Content-Length:
+ - '82'
+ response:
+ status:
+ code: 201
+ message: Created
+ headers:
+ Cache-Control:
+ - no-store, no-cache
+ Content-Type:
+ - application/json;odata.metadata=minimal;odata.streaming=true;IEEE754Compatible=false;charset=utf-8
+ Content-Encoding:
+ - gzip
+ Etag:
+ - '"{D13E6CD8-1B18-4C8B-B7F8-A3AC796798F1},1"'
+ Location:
+ - https://finn.sharepoint.com/_api/v2.0/drives('b!dmVLG22QlE2PSW0AqVB7UOhZ8n7tjkVGkgqLNnuw2ODRDvn3haLiQIhB5UYNdqMy')/items('root')/children('01AZJL5POYNQ7NCGA3RNGLP6FDVR4WPGHR')
+ Vary:
+ - Accept-Encoding
+ Strict-Transport-Security:
+ - max-age=31536000
+ Request-Id:
+ - 5d0d1aa8-576c-41e8-ae4b-5330c6f36e12
+ Client-Request-Id:
+ - 5d0d1aa8-576c-41e8-ae4b-5330c6f36e12
+ X-Ms-Ags-Diagnostic:
+ - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"4","ScaleUnit":"000","RoleInstance":"FR1PEPF0000107D"}}'
+ Odata-Version:
+ - '4.0'
+ Date:
+ - Thu, 25 Apr 2024 09:47:24 GMT
+ body:
+ encoding: UTF-8
+ string: '{"@odata.context":"https://graph.microsoft.com/v1.0/$metadata#drives(''b%21dmVLG22QlE2PSW0AqVB7UOhZ8n7tjkVGkgqLNnuw2ODRDvn3haLiQIhB5UYNdqMy'')/root/children/$entity","@odata.etag":"\"{D13E6CD8-1B18-4C8B-B7F8-A3AC796798F1},1\"","createdDateTime":"2024-04-25T09:47:24Z","eTag":"\"{D13E6CD8-1B18-4C8B-B7F8-A3AC796798F1},1\"","id":"01AZJL5POYNQ7NCGA3RNGLP6FDVR4WPGHR","lastModifiedDateTime":"2024-04-25T09:47:24Z","name":"Forbidden
+ Folder","size":0,"webUrl":"https://finn.sharepoint.com/sites/openprojectfilestoragetests/Manual%20Sharing%20Test/Forbidden%20Folder","cTag":"\"c:{D13E6CD8-1B18-4C8B-B7F8-A3AC796798F1},0\"","commentSettings":{"commentingDisabled":{"isDisabled":false}},"createdBy":{"application":{"displayName":"OpenProject
+ Dev App","id":"4262df2b-77bb-49c2-a5df-28355da676d2"},"user":{"displayName":"SharePoint
+ App"}},"lastModifiedBy":{"application":{"displayName":"OpenProject Dev App","id":"4262df2b-77bb-49c2-a5df-28355da676d2"},"user":{"displayName":"SharePoint
+ App"}},"parentReference":{"driveId":"b!dmVLG22QlE2PSW0AqVB7UOhZ8n7tjkVGkgqLNnuw2ODRDvn3haLiQIhB5UYNdqMy","driveType":"documentLibrary","id":"01AZJL5PN6Y2GOVW7725BZO354PWSELRRZ","path":"/drives/b!dmVLG22QlE2PSW0AqVB7UOhZ8n7tjkVGkgqLNnuw2ODRDvn3haLiQIhB5UYNdqMy/root:","sharepointIds":{"listId":"f7f90ed1-a285-40e2-8841-e5460d76a332","listItemUniqueId":"a7a7b4ec-acc5-4a83-a405-2cd7418e7467","siteId":"1b4b6576-906d-4d94-8f49-6d00a9507b50","siteUrl":"https://finn.sharepoint.com/sites/openprojectfilestoragetests","tenantId":"4d44bf36-9b56-45c0-8807-bbf386dd047f","webId":"7ef259e8-8eed-4645-920a-8b367bb0d8e0"}},"fileSystemInfo":{"createdDateTime":"2024-04-25T09:47:24Z","lastModifiedDateTime":"2024-04-25T09:47:24Z"},"folder":{"childCount":0},"shared":{"scope":"unknown"}}'
+ recorded_at: Thu, 25 Apr 2024 09:47:24 GMT
+- request:
+ method: get
+ uri: https://graph.microsoft.com/v1.0/drives/b!dmVLG22QlE2PSW0AqVB7UOhZ8n7tjkVGkgqLNnuw2ODRDvn3haLiQIhB5UYNdqMy/items/01AZJL5POYNQ7NCGA3RNGLP6FDVR4WPGHR?$select=id,name,fileSystemInfo,file,folder,size,createdBy,lastModifiedBy,parentReference
+ body:
+ encoding: US-ASCII
+ string: ''
+ headers:
+ Authorization:
+ - Bearer <BEARER TOKEN>
+ User-Agent:
+ - httpx.rb/1.2.4
+ Accept:
+ - "*/*"
+ Accept-Encoding:
+ - gzip, deflate
+ response:
+ status:
+ code: 404
+ message: Not Found
+ headers:
+ Cache-Control:
+ - no-store, no-cache
+ Content-Type:
+ - application/json; odata.metadata=minimal; odata.streaming=true; IEEE754Compatible=false;
+ charset=utf-8
+ Content-Encoding:
+ - gzip
+ Vary:
+ - Accept-Encoding
+ Strict-Transport-Security:
+ - max-age=31536000
+ Request-Id:
+ - d159669c-0cc9-4891-ba35-8cb549c6338d
+ Client-Request-Id:
+ - d159669c-0cc9-4891-ba35-8cb549c6338d
+ X-Ms-Ags-Diagnostic:
+ - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"4","ScaleUnit":"000","RoleInstance":"FR1PEPF000007A4"}}'
+ Date:
+ - Thu, 25 Apr 2024 09:47:24 GMT
+ body:
+ encoding: UTF-8
+ string: '{"error":{"code":"itemNotFound","message":"The resource could not be
+ found."}}'
+ recorded_at: Thu, 25 Apr 2024 09:47:25 GMT
+- request:
+ method: post
+ uri: https://login.microsoftonline.com/4d44bf36-9b56-45c0-8807-bbf386dd047f/oauth2/v2.0/token
+ body:
+ encoding: ASCII-8BIT
+ string: grant_type=client_credentials&scope=https%3A%2F%2Fgraph.microsoft.com%2F.default+offline_access&client_id=4262df2b-77bb-49c2-a5df-28355da676d2&client_secret=Vwk8Q%7EJTuPh.pAjvPiWBQBdTFMDK%7EAIwxbj9_axB
+ headers:
+ User-Agent:
+ - httpx.rb/1.2.4
+ Accept:
+ - "*/*"
+ Accept-Encoding:
+ - gzip, deflate
+ Content-Type:
+ - application/x-www-form-urlencoded
+ Content-Length:
+ - '201'
+ response:
+ status:
+ code: 200
+ message: OK
+ headers:
+ Cache-Control:
+ - no-store, no-cache
+ Pragma:
+ - no-cache
+ Content-Type:
+ - application/json; charset=utf-8
+ Expires:
+ - "-1"
+ Strict-Transport-Security:
+ - max-age=31536000; includeSubDomains
+ X-Content-Type-Options:
+ - nosniff
+ P3p:
+ - CP="DSP CUR OTPi IND OTRi ONL FIN"
+ X-Ms-Request-Id:
+ - 1928c9e5-2a3f-40ca-a045-df7153a9b500
+ X-Ms-Ests-Server:
+ - 2.1.17846.6 - FRC ProdSlices
+ X-Ms-Srs:
+ - 1.P
+ X-Xss-Protection:
+ - '0'
+ Set-Cookie:
+ - fpc=AkmNlzqUsAhBicjKNc8eYxKkbDoXAQAAAKwdvN0OAAAA; expires=Sat, 25-May-2024
+ 09:47:25 GMT; path=/; secure; HttpOnly; SameSite=None, x-ms-gateway-slice=estsfd;
+ path=/; secure; samesite=none; httponly, stsservicecookie=estsfd; path=/;
+ secure; samesite=none; httponly
+ Date:
+ - Thu, 25 Apr 2024 09:47:24 GMT
+ Content-Length:
+ - '1735'
+ body:
+ encoding: UTF-8
+ string: '{"token_type":"Bearer","expires_in":3599,"ext_expires_in":3599,"access_token":"<ACCESS_TOKEN>"}'
+ recorded_at: Thu, 25 Apr 2024 09:47:25 GMT
+- request:
+ method: get
+ uri: https://graph.microsoft.com/v1.0/drives/b!dmVLG22QlE2PSW0AqVB7UOhZ8n7tjkVGkgqLNnuw2ODRDvn3haLiQIhB5UYNdqMy/items/01AZJL5POYNQ7NCGA3RNGLP6FDVR4WPGHR?$select=id,name,fileSystemInfo,file,folder,size,createdBy,lastModifiedBy,parentReference
+ body:
+ encoding: US-ASCII
+ string: ''
+ headers:
+ User-Agent:
+ - httpx.rb/1.2.4
+ Accept:
+ - "*/*"
+ Accept-Encoding:
+ - gzip, deflate
+ Authorization:
+ - Bearer <BEARER TOKEN>
+ response:
+ status:
+ code: 200
+ message: OK
+ headers:
+ Cache-Control:
+ - no-cache
+ Content-Type:
+ - application/json; odata.metadata=minimal; odata.streaming=true; IEEE754Compatible=false;
+ charset=utf-8
+ Content-Encoding:
+ - gzip
+ Strict-Transport-Security:
+ - max-age=31536000
+ Request-Id:
+ - 456700b3-96ec-43c7-80b9-5df523b5b5f0
+ Client-Request-Id:
+ - 456700b3-96ec-43c7-80b9-5df523b5b5f0
+ X-Ms-Ags-Diagnostic:
+ - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"4","ScaleUnit":"000","RoleInstance":"FR1PEPF000007AC"}}'
+ Date:
+ - Thu, 25 Apr 2024 09:47:25 GMT
+ body:
+ encoding: UTF-8
+ string: '{"@odata.context":"https://graph.microsoft.com/v1.0/$metadata#Collection(driveItem)/$entity","@odata.etag":"\"{D13E6CD8-1B18-4C8B-B7F8-A3AC796798F1},2\"","createdBy":{"application":{"id":"4262df2b-77bb-49c2-a5df-28355da676d2","displayName":"OpenProject
+ Dev App"},"user":{"displayName":"SharePoint App"}},"id":"01AZJL5POYNQ7NCGA3RNGLP6FDVR4WPGHR","lastModifiedBy":{"application":{"id":"4262df2b-77bb-49c2-a5df-28355da676d2","displayName":"OpenProject
+ Dev App"},"user":{"displayName":"SharePoint App"}},"name":"Forbidden Folder","parentReference":{"driveType":"documentLibrary","driveId":"b!dmVLG22QlE2PSW0AqVB7UOhZ8n7tjkVGkgqLNnuw2ODRDvn3haLiQIhB5UYNdqMy","id":"01AZJL5PN6Y2GOVW7725BZO354PWSELRRZ","name":"Manual
+ Sharing Test","path":"/drives/b!dmVLG22QlE2PSW0AqVB7UOhZ8n7tjkVGkgqLNnuw2ODRDvn3haLiQIhB5UYNdqMy/root:","siteId":"1b4b6576-906d-4d94-8f49-6d00a9507b50"},"fileSystemInfo":{"createdDateTime":"2024-04-25T09:47:24Z","lastModifiedDateTime":"2024-04-25T09:47:24Z"},"folder":{"childCount":0},"size":0}'
+ recorded_at: Thu, 25 Apr 2024 09:47:25 GMT
+- request:
+ method: post
+ uri: https://login.microsoftonline.com/4d44bf36-9b56-45c0-8807-bbf386dd047f/oauth2/v2.0/token
+ body:
+ encoding: ASCII-8BIT
+ string: grant_type=client_credentials&scope=https%3A%2F%2Fgraph.microsoft.com%2F.default+offline_access&client_id=4262df2b-77bb-49c2-a5df-28355da676d2&client_secret=Vwk8Q%7EJTuPh.pAjvPiWBQBdTFMDK%7EAIwxbj9_axB
+ headers:
+ User-Agent:
+ - httpx.rb/1.2.4
+ Accept:
+ - "*/*"
+ Accept-Encoding:
+ - gzip, deflate
+ Content-Type:
+ - application/x-www-form-urlencoded
+ Content-Length:
+ - '201'
+ response:
+ status:
+ code: 200
+ message: OK
+ headers:
+ Cache-Control:
+ - no-store, no-cache
+ Pragma:
+ - no-cache
+ Content-Type:
+ - application/json; charset=utf-8
+ Expires:
+ - "-1"
+ Strict-Transport-Security:
+ - max-age=31536000; includeSubDomains
+ X-Content-Type-Options:
+ - nosniff
+ P3p:
+ - CP="DSP CUR OTPi IND OTRi ONL FIN"
+ X-Ms-Request-Id:
+ - 9c178365-2d3d-4c25-b160-4584064cc000
+ X-Ms-Ests-Server:
+ - 2.1.17846.6 - FRC ProdSlices
+ X-Ms-Srs:
+ - 1.P
+ X-Xss-Protection:
+ - '0'
+ Set-Cookie:
+ - fpc=AuohO-25QkJDph7AQcb6W2ukbDoXAQAAAK4dvN0OAAAA; expires=Sat, 25-May-2024
+ 09:47:26 GMT; path=/; secure; HttpOnly; SameSite=None, x-ms-gateway-slice=estsfd;
+ path=/; secure; samesite=none; httponly, stsservicecookie=estsfd; path=/;
+ secure; samesite=none; httponly
+ Date:
+ - Thu, 25 Apr 2024 09:47:25 GMT
+ Content-Length:
+ - '1735'
+ body:
+ encoding: UTF-8
+ string: '{"token_type":"Bearer","expires_in":3599,"ext_expires_in":3599,"access_token":"<ACCESS_TOKEN>"}'
+ recorded_at: Thu, 25 Apr 2024 09:47:26 GMT
+- request:
+ method: delete
+ uri: https://graph.microsoft.com/v1.0/drives/b!dmVLG22QlE2PSW0AqVB7UOhZ8n7tjkVGkgqLNnuw2ODRDvn3haLiQIhB5UYNdqMy/items/01AZJL5POYNQ7NCGA3RNGLP6FDVR4WPGHR
+ body:
+ encoding: US-ASCII
+ string: ''
+ headers:
+ User-Agent:
+ - httpx.rb/1.2.4
+ Accept:
+ - "*/*"
+ Accept-Encoding:
+ - gzip, deflate
+ Authorization:
+ - Bearer <BEARER TOKEN>
+ response:
+ status:
+ code: 204
+ message: No Content
+ headers:
+ Cache-Control:
+ - no-store, no-cache
+ Strict-Transport-Security:
+ - max-age=31536000
+ Request-Id:
+ - 81112f90-1d8b-4d06-89e7-e168463427d8
+ Client-Request-Id:
+ - 81112f90-1d8b-4d06-89e7-e168463427d8
+ X-Ms-Ags-Diagnostic:
+ - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"4","ScaleUnit":"000","RoleInstance":"FR1PEPF000010A0"}}'
+ Date:
+ - Thu, 25 Apr 2024 09:47:26 GMT
+ body:
+ encoding: UTF-8
+ string: ''
+ recorded_at: Thu, 25 Apr 2024 09:47:26 GMT
+recorded_with: VCR 6.2.0
diff --git a/modules/storages/spec/support/fixtures/vcr_cassettes/one_drive/file_info_query_not_found.yml b/modules/storages/spec/support/fixtures/vcr_cassettes/one_drive/file_info_query_not_found.yml
new file mode 100644
index 00000000000..3c0f5ac2061
--- /dev/null
+++ b/modules/storages/spec/support/fixtures/vcr_cassettes/one_drive/file_info_query_not_found.yml
@@ -0,0 +1,144 @@
+---
+http_interactions:
+- request:
+ method: get
+ uri: https://graph.microsoft.com/v1.0/drives/b!dmVLG22QlE2PSW0AqVB7UOhZ8n7tjkVGkgqLNnuw2OBb-brzKzZAR4DYT1k9KPXs/items/not_existent?$select=id,name,fileSystemInfo,file,folder,size,createdBy,lastModifiedBy,parentReference
+ body:
+ encoding: US-ASCII
+ string: ''
+ headers:
+ Authorization:
+ - Bearer <BEARER TOKEN>
+ User-Agent:
+ - httpx.rb/1.2.4
+ Accept:
+ - "*/*"
+ Accept-Encoding:
+ - gzip, deflate
+ response:
+ status:
+ code: 404
+ message: Not Found
+ headers:
+ Cache-Control:
+ - no-store, no-cache
+ Content-Type:
+ - application/json; charset=utf-8
+ Content-Encoding:
+ - gzip
+ Vary:
+ - Accept-Encoding
+ Strict-Transport-Security:
+ - max-age=31536000
+ Request-Id:
+ - e8f4d212-b8de-4c44-9c99-f3f44761314d
+ Client-Request-Id:
+ - e8f4d212-b8de-4c44-9c99-f3f44761314d
+ X-Ms-Ags-Diagnostic:
+ - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"4","ScaleUnit":"000","RoleInstance":"FR1PEPF0000109D"}}'
+ Date:
+ - Thu, 25 Apr 2024 09:40:30 GMT
+ body:
+ encoding: UTF-8
+ string: '{"error":{"code":"itemNotFound","message":"Item not found"}}'
+ recorded_at: Thu, 25 Apr 2024 09:40:31 GMT
+- request:
+ method: post
+ uri: https://login.microsoftonline.com/4d44bf36-9b56-45c0-8807-bbf386dd047f/oauth2/v2.0/token
+ body:
+ encoding: ASCII-8BIT
+ string: grant_type=client_credentials&scope=https%3A%2F%2Fgraph.microsoft.com%2F.default+offline_access&client_id=4262df2b-77bb-49c2-a5df-28355da676d2&client_secret=Vwk8Q%7EJTuPh.pAjvPiWBQBdTFMDK%7EAIwxbj9_axB
+ headers:
+ User-Agent:
+ - httpx.rb/1.2.4
+ Accept:
+ - "*/*"
+ Accept-Encoding:
+ - gzip, deflate
+ Content-Type:
+ - application/x-www-form-urlencoded
+ Content-Length:
+ - '201'
+ response:
+ status:
+ code: 200
+ message: OK
+ headers:
+ Cache-Control:
+ - no-store, no-cache
+ Pragma:
+ - no-cache
+ Content-Type:
+ - application/json; charset=utf-8
+ Expires:
+ - "-1"
+ Strict-Transport-Security:
+ - max-age=31536000; includeSubDomains
+ X-Content-Type-Options:
+ - nosniff
+ P3p:
+ - CP="DSP CUR OTPi IND OTRi ONL FIN"
+ X-Ms-Request-Id:
+ - 102e41d2-ebf8-4412-8a93-1f5e31309800
+ X-Ms-Ests-Server:
+ - 2.1.17846.6 - WEULR1 ProdSlices
+ X-Ms-Srs:
+ - 1.P
+ X-Xss-Protection:
+ - '0'
+ Set-Cookie:
+ - fpc=Aq6ssGKvEZdKjk_vkF-IR9akbDoXAQAAAA8cvN0OAAAA; expires=Sat, 25-May-2024
+ 09:40:32 GMT; path=/; secure; HttpOnly; SameSite=None, x-ms-gateway-slice=estsfd;
+ path=/; secure; samesite=none; httponly, stsservicecookie=estsfd; path=/;
+ secure; samesite=none; httponly
+ Date:
+ - Thu, 25 Apr 2024 09:40:31 GMT
+ Content-Length:
+ - '1735'
+ body:
+ encoding: UTF-8
+ string: '{"token_type":"Bearer","expires_in":3599,"ext_expires_in":3599,"access_token":"<ACCESS_TOKEN>"}'
+ recorded_at: Thu, 25 Apr 2024 09:40:32 GMT
+- request:
+ method: get
+ uri: https://graph.microsoft.com/v1.0/drives/b!dmVLG22QlE2PSW0AqVB7UOhZ8n7tjkVGkgqLNnuw2OBb-brzKzZAR4DYT1k9KPXs/items/not_existent?$select=id,name,fileSystemInfo,file,folder,size,createdBy,lastModifiedBy,parentReference
+ body:
+ encoding: US-ASCII
+ string: ''
+ headers:
+ User-Agent:
+ - httpx.rb/1.2.4
+ Accept:
+ - "*/*"
+ Accept-Encoding:
+ - gzip, deflate
+ Authorization:
+ - Bearer <BEARER TOKEN>
+ response:
+ status:
+ code: 404
+ message: Not Found
+ headers:
+ Cache-Control:
+ - no-store, no-cache
+ Content-Type:
+ - application/json; charset=utf-8
+ Content-Encoding:
+ - gzip
+ Vary:
+ - Accept-Encoding
+ Strict-Transport-Security:
+ - max-age=31536000
+ Request-Id:
+ - 303046bb-b35f-445f-94b0-0c3616a26892
+ Client-Request-Id:
+ - 303046bb-b35f-445f-94b0-0c3616a26892
+ X-Ms-Ags-Diagnostic:
+ - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"4","ScaleUnit":"000","RoleInstance":"FR1PEPF00000C2E"}}'
+ Date:
+ - Thu, 25 Apr 2024 09:40:31 GMT
+ body:
+ encoding: UTF-8
+ string: '{"error":{"code":"itemNotFound","message":"Item not found"}}'
+ recorded_at: Thu, 25 Apr 2024 09:40:32 GMT
+recorded_with: VCR 6.2.0
diff --git a/modules/storages/spec/support/fixtures/vcr_cassettes/one_drive/file_info_query_one_not_found.yml b/modules/storages/spec/support/fixtures/vcr_cassettes/one_drive/file_info_query_one_not_found.yml
deleted file mode 100644
index 9d75f803fb5..00000000000
--- a/modules/storages/spec/support/fixtures/vcr_cassettes/one_drive/file_info_query_one_not_found.yml
+++ /dev/null
@@ -1,47 +0,0 @@
----
-http_interactions:
-- request:
- method: get
- uri: https://graph.microsoft.com/v1.0/drives/b!dmVLG22QlE2PSW0AqVB7UOhZ8n7tjkVGkgqLNnuw2OBb-brzKzZAR4DYT1k9KPXs/items/not_existent?$select=id,name,fileSystemInfo,file,folder,size,createdBy,lastModifiedBy,parentReference
- body:
- encoding: US-ASCII
- string: ''
- headers:
- Authorization:
- - Bearer <BEARER TOKEN>
- User-Agent:
- - httpx.rb/1.2.1
- Accept:
- - "*/*"
- Accept-Encoding:
- - gzip, deflate
- response:
- status:
- code: 404
- message: Not Found
- headers:
- Cache-Control:
- - no-store, no-cache
- Transfer-Encoding:
- - chunked
- Content-Type:
- - application/json; charset=utf-8
- Content-Encoding:
- - gzip
- Vary:
- - Accept-Encoding
- Strict-Transport-Security:
- - max-age=31536000
- Request-Id:
- - feb96c62-6f97-4ad2-8b61-947cd4d18f30
- Client-Request-Id:
- - feb96c62-6f97-4ad2-8b61-947cd4d18f30
- X-Ms-Ags-Diagnostic:
- - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"5","ScaleUnit":"005","RoleInstance":"FR3PEPF00000464"}}'
- Date:
- - Tue, 30 Jan 2024 11:56:01 GMT
- body:
- encoding: UTF-8
- string: '{"error":{"code":"itemNotFound","message":"Item not found"}}'
- recorded_at: Tue, 30 Jan 2024 11:56:02 GMT
-recorded_with: VCR 6.2.0
diff --git a/modules/storages/spec/support/fixtures/vcr_cassettes/one_drive/file_info_query_success_file.yml b/modules/storages/spec/support/fixtures/vcr_cassettes/one_drive/file_info_query_success_file.yml
index 509f0d594ff..acc4b24bea7 100644
--- a/modules/storages/spec/support/fixtures/vcr_cassettes/one_drive/file_info_query_success_file.yml
+++ b/modules/storages/spec/support/fixtures/vcr_cassettes/one_drive/file_info_query_success_file.yml
@@ -10,7 +10,7 @@ http_interactions:
Authorization:
- Bearer <BEARER TOKEN>
User-Agent:
- - httpx.rb/1.2.1
+ - httpx.rb/1.2.4
Accept:
- "*/*"
Accept-Encoding:
@@ -22,8 +22,6 @@ http_interactions:
headers:
Cache-Control:
- no-cache
- Transfer-Encoding:
- - chunked
Content-Type:
- application/json; odata.metadata=minimal; odata.streaming=true; IEEE754Compatible=false;
charset=utf-8
@@ -32,17 +30,17 @@ http_interactions:
Strict-Transport-Security:
- max-age=31536000
Request-Id:
- - 2fa26f33-24ef-4ae7-96e8-9c043ecfd012
+ - ebd96740-b499-4757-abad-c92006a8c2c4
Client-Request-Id:
- - 2fa26f33-24ef-4ae7-96e8-9c043ecfd012
+ - ebd96740-b499-4757-abad-c92006a8c2c4
X-Ms-Ags-Diagnostic:
- - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"5","ScaleUnit":"005","RoleInstance":"FR3PEPF000002E4"}}'
+ - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"4","ScaleUnit":"000","RoleInstance":"FR1PEPF0000107E"}}'
Date:
- - Tue, 30 Jan 2024 11:56:00 GMT
+ - Thu, 25 Apr 2024 09:46:07 GMT
body:
encoding: UTF-8
string: '{"@odata.context":"https://graph.microsoft.com/v1.0/$metadata#Collection(driveItem)/$entity","@odata.etag":"\"{128880A2-6DA3-4DFA-995F-A075F7ACED60},3\"","createdBy":{"user":{"email":"[email protected]","id":"0a0d38a9-a59b-4245-93fa-0d2cf727f17a","displayName":"Eric
Schubert"}},"id":"01AZJL5PNCQCEBFI3N7JGZSX5AOX32Z3LA","lastModifiedBy":{"user":{"email":"[email protected]","id":"0a0d38a9-a59b-4245-93fa-0d2cf727f17a","displayName":"Eric
Schubert"}},"name":"NextcloudHub.md","parentReference":{"driveType":"documentLibrary","driveId":"b!dmVLG22QlE2PSW0AqVB7UOhZ8n7tjkVGkgqLNnuw2OBb-brzKzZAR4DYT1k9KPXs","id":"01AZJL5PPWP5UOATNRJJBYJG5TACDHEUAG","name":"Subfolder","path":"/drives/b!dmVLG22QlE2PSW0AqVB7UOhZ8n7tjkVGkgqLNnuw2OBb-brzKzZAR4DYT1k9KPXs/root:/Folder/Subfolder","siteId":"1b4b6576-906d-4d94-8f49-6d00a9507b50"},"file":{"hashes":{"quickXorHash":"2HQJc625zkgBM9NAAjuXr1Im/0M="},"mimeType":"application/octet-stream"},"fileSystemInfo":{"createdDateTime":"2023-09-26T14:45:25Z","lastModifiedDateTime":"2023-09-26T14:46:13Z"},"size":1095}'
- recorded_at: Tue, 30 Jan 2024 11:56:01 GMT
+ recorded_at: Thu, 25 Apr 2024 09:46:08 GMT
recorded_with: VCR 6.2.0
diff --git a/modules/storages/spec/support/fixtures/vcr_cassettes/one_drive/file_info_query_success_folder.yml b/modules/storages/spec/support/fixtures/vcr_cassettes/one_drive/file_info_query_success_folder.yml
index 7827c355f60..c14e1424c81 100644
--- a/modules/storages/spec/support/fixtures/vcr_cassettes/one_drive/file_info_query_success_folder.yml
+++ b/modules/storages/spec/support/fixtures/vcr_cassettes/one_drive/file_info_query_success_folder.yml
@@ -10,7 +10,7 @@ http_interactions:
Authorization:
- Bearer <BEARER TOKEN>
User-Agent:
- - httpx.rb/1.2.1
+ - httpx.rb/1.2.4
Accept:
- "*/*"
Accept-Encoding:
@@ -22,8 +22,6 @@ http_interactions:
headers:
Cache-Control:
- no-cache
- Transfer-Encoding:
- - chunked
Content-Type:
- application/json; odata.metadata=minimal; odata.streaming=true; IEEE754Compatible=false;
charset=utf-8
@@ -32,17 +30,17 @@ http_interactions:
Strict-Transport-Security:
- max-age=31536000
Request-Id:
- - bbe5d119-0f93-4ac7-be44-ca15c3b35e3f
+ - eb6e0b8f-924f-4e15-b35b-92f96ed3d55c
Client-Request-Id:
- - bbe5d119-0f93-4ac7-be44-ca15c3b35e3f
+ - eb6e0b8f-924f-4e15-b35b-92f96ed3d55c
X-Ms-Ags-Diagnostic:
- - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"5","ScaleUnit":"005","RoleInstance":"FR3PEPF0000045F"}}'
+ - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"4","ScaleUnit":"004","RoleInstance":"FR2PEPF00000553"}}'
Date:
- - Tue, 30 Jan 2024 11:56:01 GMT
+ - Thu, 25 Apr 2024 09:46:37 GMT
body:
encoding: UTF-8
string: '{"@odata.context":"https://graph.microsoft.com/v1.0/$metadata#Collection(driveItem)/$entity","@odata.etag":"\"{D67AC1B0-566D-41C3-B8A4-E94075763181},2\"","createdBy":{"user":{"email":"[email protected]","id":"0a0d38a9-a59b-4245-93fa-0d2cf727f17a","displayName":"Eric
Schubert"}},"id":"01AZJL5PNQYF5NM3KWYNA3RJHJIB2XMMMB","lastModifiedBy":{"user":{"email":"[email protected]","id":"0a0d38a9-a59b-4245-93fa-0d2cf727f17a","displayName":"Eric
- Schubert"}},"name":"\u00dcml\u00e6\u00fbts","parentReference":{"driveType":"documentLibrary","driveId":"b!dmVLG22QlE2PSW0AqVB7UOhZ8n7tjkVGkgqLNnuw2OBb-brzKzZAR4DYT1k9KPXs","id":"01AZJL5PMAXGDWAAKMEBALX4Q6GSN5BSBR","name":"Folder","path":"/drives/b!dmVLG22QlE2PSW0AqVB7UOhZ8n7tjkVGkgqLNnuw2OBb-brzKzZAR4DYT1k9KPXs/root:/Folder","siteId":"1b4b6576-906d-4d94-8f49-6d00a9507b50"},"fileSystemInfo":{"createdDateTime":"2023-10-09T15:26:32Z","lastModifiedDateTime":"2023-10-09T15:26:32Z"},"folder":{"childCount":1},"size":18007}'
- recorded_at: Tue, 30 Jan 2024 11:56:01 GMT
+ Schubert"}},"name":"\u00dcml\u00e6\u00fbts","parentReference":{"driveType":"documentLibrary","driveId":"b!dmVLG22QlE2PSW0AqVB7UOhZ8n7tjkVGkgqLNnuw2OBb-brzKzZAR4DYT1k9KPXs","id":"01AZJL5PMAXGDWAAKMEBALX4Q6GSN5BSBR","name":"Folder","path":"/drives/b!dmVLG22QlE2PSW0AqVB7UOhZ8n7tjkVGkgqLNnuw2OBb-brzKzZAR4DYT1k9KPXs/root:/Folder","siteId":"1b4b6576-906d-4d94-8f49-6d00a9507b50"},"fileSystemInfo":{"createdDateTime":"2023-10-09T15:26:32Z","lastModifiedDateTime":"2023-10-09T15:26:32Z"},"folder":{"childCount":1,"decorator":{"iconColor":"darkTeal"}},"size":20789}'
+ recorded_at: Thu, 25 Apr 2024 09:46:37 GMT
recorded_with: VCR 6.2.0
diff --git a/modules/storages/spec/support/fixtures/vcr_cassettes/one_drive/files_info_query_one_not_found.yml b/modules/storages/spec/support/fixtures/vcr_cassettes/one_drive/files_info_query_one_not_found.yml
index c196f0e0e27..064681f4dd8 100644
--- a/modules/storages/spec/support/fixtures/vcr_cassettes/one_drive/files_info_query_one_not_found.yml
+++ b/modules/storages/spec/support/fixtures/vcr_cassettes/one_drive/files_info_query_one_not_found.yml
@@ -10,11 +10,117 @@ http_interactions:
Authorization:
- Bearer <BEARER TOKEN>
User-Agent:
- - httpx.rb/1.2.1
+ - httpx.rb/1.2.4
Accept:
- "*/*"
Accept-Encoding:
- gzip, deflate
+ response:
+ status:
+ code: 401
+ message: Unauthorized
+ headers:
+ Content-Type:
+ - application/json
+ Content-Encoding:
+ - gzip
+ Vary:
+ - Accept-Encoding
+ Strict-Transport-Security:
+ - max-age=31536000
+ Request-Id:
+ - ee8c6eb1-6433-4065-b9d9-34f8b9d6a841
+ Client-Request-Id:
+ - ee8c6eb1-6433-4065-b9d9-34f8b9d6a841
+ X-Ms-Ags-Diagnostic:
+ - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"4","ScaleUnit":"005","RoleInstance":"FR3PEPF0000054E"}}'
+ Www-Authenticate:
+ - Bearer realm="", authorization_uri="https://login.microsoftonline.com/common/oauth2/authorize",
+ client_id="00000003-0000-0000-c000-000000000000"
+ Date:
+ - Thu, 25 Apr 2024 13:51:28 GMT
+ body:
+ encoding: UTF-8
+ string: '{"error":{"code":"InvalidAuthenticationToken","message":"Lifetime validation
+ failed, the token is expired.","innerError":{"date":"2024-04-25T13:51:28","request-id":"ee8c6eb1-6433-4065-b9d9-34f8b9d6a841","client-request-id":"ee8c6eb1-6433-4065-b9d9-34f8b9d6a841"}}}'
+ recorded_at: Thu, 25 Apr 2024 13:51:28 GMT
+- request:
+ method: post
+ uri: https://login.microsoftonline.com/4d44bf36-9b56-45c0-8807-bbf386dd047f/oauth2/v2.0/token
+ body:
+ encoding: ASCII-8BIT
+ string: grant_type=refresh_token&scope=https%3A%2F%2Fgraph.microsoft.com%2F.default+offline_access&client_id=4262df2b-77bb-49c2-a5df-28355da676d2&client_secret=Vwk8Q%7EJTuPh.pAjvPiWBQBdTFMDK%7EAIwxbj9_axB&refresh_token=0.AQkANr9ETVabwEWIB7vzht0EfyvfYkK7d8JJpd8oNV2mdtIJAE4.AgABAwEAAADnfolhJpSnRYB1SVj-Hgd8AgDs_wUA9P_diHW6bDhe23QNDcLxox9BCAFs_rdN6aZo6bcTA2g2IhWaKSOQ8bEKyi0WmbJw3_I8LZdNwYRWsko9J5tNkN8WQloCG7VPtR4I3RO5Pnl99-bdo01xwUcwIfoYGhXy7ckY09-6jqcyOs4ArHsC0QGb2EYs0Ir5Rv6Wr_Co6iZp4euuZVqDuIO54xoIJ322pFtpJLRBtb0HUqy8W9iWHNM86xjrRn5XqTJNp_PVgL7jVfkucuZCRC4ZfvuDV9921kqsJN5DlCIfCYLq9L76DkiFsRpSr4BbsEUDyQlYUE6vto6QU8KoVUdUEkCnjVHY9CAODwVxAeSsRUOwqoIKUQPN7m47iocrNJ7mcWxYeVFGVMXsECPC_vnWffdCZKHO6i3xpXaFBADwUg6YVs-7ESlxZ8I8Z6CouGhxtnMpMvQvYUoOlgKB3tAfXsoZU0Y3fMCzX-1bMl47oZiGh91uME-IPb1UlcmMoQf09_MlQbKhmeCOcd3H2YnPLhfsH1-wUy3bJb-dQQi4UVPK1qEi5q7n9_9VMHX1q3B3avX7r8Jf-FJb79VeiGW3ZqDJV4FCpecLeoZpXprIzCFrgNOY99ldYrRgP-BdRees5veipoonQFD6jyFjTR4CNFhXCqZZV9dBdRMQ2KO7cgGke3JQtEkSluKDqSEhuZUkZqqjDHf_nTr0kwaPI6QWDsB-F-BFyu1z_xA0gwHj-ETOOcsz-AxGFTfpGBS066BD4V504xxOx8i4-ZqGB53oA3xRB9Ds_zkQ8a3GWodHxMJw9_IBAo8lKhQ19w40EdfKbdebFrQtSynHXUE6Snko6GqH0L-dEeTlWjf5I4_gFfWk_LjpgeZnmRWWvWsoed8Eq8ZrQZralr92HSY6Wwql1o6VaVkDkUgMzkzzPf70t2Kq5Tt9ODarnuWeDUuCLyoGFgBX8REcmlxAZM1ajw6wNhiYnAIgtLcG1rt86Io__r8DJemO7dDOBtHjNJq-EkU0vsdhP-UJs0Rszo9n1Zz61Lma3xr5pBMOAW56tRHBkae-gBp60wl6Ad8VhkQ5r76M3GjsSvaVPC4R2_fkvD5q-pZzHEtZopqDIMBpEyfFzeygkVlPiOr2jqmN9Lqy2aBPXklBkoNA0NWsKr74HsQBgfEjVIEtFVWukv6EYOdTCfbr7R3P-2AvJ75HDB8Yt_jqmQmKd5PxYOAPkNnhfs1vBLZ9yhKk00dWV_aZMoXl349DIcbHYz0hr1UbOSAolq8fP-zjZSI1arhVqbgrLyw_t3k9bBrLcNvN4lFQIR_gm_4q6vvUAZdn-VLQUH3R1-4KZODfFXk41HvyQ2CDXY9amKmDD1VLVgP0MEu5pQmue6MfRqYHYcFThSfw0JNCnliR70nEklGTQtPkrMu24gPQMT_DoblNhlo3WWXPcDOha2X3bBPsSdLYHF4_yaYgJsj-U3YpsyprX8a4M0jffvfynM5oKdS73i-oHgcemnMtwBNRbfxdvs-nJTXbcsKC9Ac
+ headers:
+ User-Agent:
+ - httpx.rb/1.2.4
+ Accept:
+ - "*/*"
+ Accept-Encoding:
+ - gzip, deflate
+ Content-Type:
+ - application/x-www-form-urlencoded
+ Content-Length:
+ - '1812'
+ response:
+ status:
+ code: 200
+ message: OK
+ headers:
+ Cache-Control:
+ - no-store, no-cache
+ Pragma:
+ - no-cache
+ Content-Type:
+ - application/json; charset=utf-8
+ Expires:
+ - "-1"
+ Strict-Transport-Security:
+ - max-age=31536000; includeSubDomains
+ X-Content-Type-Options:
+ - nosniff
+ P3p:
+ - CP="DSP CUR OTPi IND OTRi ONL FIN"
+ X-Ms-Request-Id:
+ - fe337949-2ea7-46b0-8001-31ed10efb700
+ X-Ms-Ests-Server:
+ - 2.1.17846.6 - FRC ProdSlices
+ X-Ms-Srs:
+ - 1.P
+ X-Xss-Protection:
+ - '0'
+ Set-Cookie:
+ - fpc=AvwAm1VZpNZEiwmqDOLCvit9yQTNAQAAAOBWvN0OAAAA; expires=Sat, 25-May-2024
+ 13:51:28 GMT; path=/; secure; HttpOnly; SameSite=None, x-ms-gateway-slice=estsfd;
+ path=/; secure; samesite=none; httponly, stsservicecookie=estsfd; path=/;
+ secure; samesite=none; httponly
+ Date:
+ - Thu, 25 Apr 2024 13:51:27 GMT
+ Connection:
+ - close
+ Content-Length:
+ - '4366'
+ body:
+ encoding: UTF-8
+ string: '{"token_type":"Bearer","scope":"profile openid email https://graph.microsoft.com/Directory.ReadWrite.All
+ https://graph.microsoft.com/Files.ReadWrite.All https://graph.microsoft.com/Sites.Read.All
+ https://graph.microsoft.com/Sites.ReadWrite.All https://graph.microsoft.com/User.Read
+ https://graph.microsoft.com/.default","expires_in":3606,"ext_expires_in":3606,"access_token":"<ACCESS_TOKEN>","refresh_token":"0.AQkANr9ETVabwEWIB7vzht0EfyvfYkK7d8JJpd8oNV2mdtIJAE4.AgABAwEAAADnfolhJpSnRYB1SVj-Hgd8AgDs_wUA9P-sDDHa2BVRSkTTExtCWmbHQ3ng2s2_Eg-R5lxELM8iUK_l2FkU3D_yABYGoplQR5x1fHIv-Bio-XbO5-GMFxlcTsBPMV6CCqqNMmgTUkVVrQNUmW7Vh_RR131R2GN16lBlnWbj0OWJxFkUVDL9kgPCwGrQLrdMojJ4Lgv4kOj0Fe2De29dC5CvV1kxt2lkwtcjTemyM47WT0GXCTgaO72hTK-z0eNxQ_p7dWti8iJ0dT8npoXNOxvhJt5qvfMYSGlgVVMPkmz_cRAt0hLYpk_TrnE_PBdsHWIRiM1TePjI2haopCjqze5RBu7WlSnZyw2kvtmd-fq7h4sfZgUpowpAsq7fFymacBoUXa3i3b1A8cVDqsvSDJQ1Rf-869B6K4YOocPuYX0A_0E-y6tDQ79Z2kAM_olytRKF5Moil0Fba8PcbQuZGha9T1fUiEWn2QPOuumcqEJVQkmtRLHq5cokhF87qfDLuHl4y1xy3HJX0QzJm0sLXsGutq43KcXxQD_er1ufi1UQxO3esIDhPEJlAW_E8gjvyMuO5-T6Zmrzyz-Im74Vurq3bFJAE7JQ4NnpFvkLmSUUrdu5RQit7jA4ZXdh6aSDE8UWxcdrlJ_j4-xafAH2FTwgBCZ74jtW_Vf5b8mTGlDiGwynkzDn5dClrXMto0CQSbQupxmIX9rkilsf8NvY-gp9E4CcyH9e2J1G-vucF7jmuXEporIdWCZ0v8RQ1eP0bcO6mLMxC6LKZTellhWmuzo1d7tlj8-YTjLAjlDea197vMl7bXMfFFhY6P7EBMd9ZzdB13bY8Un7Lvjui-ALwmMZGolC5-QK5NiVrMn0Cy-lbibJAnF4Y9QkG4QmVdDmoXg2vRl38huLfaCJ3bELxajRdIFW_z6tzFnUzNofCCRn4-aSYS9m3I-psLQ9Y_6BVpgUp42m1ynJuEuDvLG4GWQpQQhjOKoeKQnjcXOxUdLuAYe_VOvNBgcQwXZdaRarfkmD83t1fLFLkhlhmILGMj1HAQFPrzMaOEHPicv8TyaIJngpIAHMjxDg0ikTzDH01qydMZH1fgJc5E7iEn4sHyb6Vri7aqnj8rXGbm0z2usZrMWgetJ6LIwRa6H5vgtJFc8rt021HbEMVs3MBIPhkPPDlnNvACb-B5NbBeekcTL9EPoFVnZBZrHNDuy8Lsrd0C53_hpP1UncMw--nICskuNRX8DN7reybe93_I9suaXlEX7wgpZ0s7Pdwm8BYTrJ9f7fCFtA_IzUpCtVeKyW8zeacmLJIgJyMhqf8zxzJsH-JSrIw1boxWCnem9PMlWP1RP_osFFlApqCwGUydawzagETdTc5moQyGgMAbPpQ8iIsOLG2Hs2JpRKwLo-byN_-yA66La7q5va8uTm7wK21GeavrD-vm3VpW3g7XjmOhvW0GL3lYRAx37-ogpjmyBhm2FjFiJ6Buu5qHEjj4qRC3SgVsKLz2ogUNrruLOH7wF56Q8jLTp6il4WluuGcGg7hUQ"}'
+ recorded_at: Thu, 25 Apr 2024 13:51:28 GMT
+- request:
+ method: get
+ uri: https://graph.microsoft.com/v1.0/drives/b!dmVLG22QlE2PSW0AqVB7UOhZ8n7tjkVGkgqLNnuw2OBb-brzKzZAR4DYT1k9KPXs/items/01AZJL5PJTICED3C5YSVAY6NWTBNA2XERU?$select=id,name,fileSystemInfo,file,folder,size,createdBy,lastModifiedBy,parentReference
+ body:
+ encoding: US-ASCII
+ string: ''
+ headers:
+ User-Agent:
+ - httpx.rb/1.2.4
+ Accept:
+ - "*/*"
+ Accept-Encoding:
+ - gzip, deflate
+ Authorization:
+ - Bearer <BEARER TOKEN>
response:
status:
code: 200
@@ -22,8 +128,6 @@ http_interactions:
headers:
Cache-Control:
- no-cache
- Transfer-Encoding:
- - chunked
Content-Type:
- application/json; odata.metadata=minimal; odata.streaming=true; IEEE754Compatible=false;
charset=utf-8
@@ -32,19 +136,19 @@ http_interactions:
Strict-Transport-Security:
- max-age=31536000
Request-Id:
- - f04d52dd-14d7-44bb-9f5c-b472dbf0b7a8
+ - fea83d0b-352a-496c-9d2d-1e6b0dbc1e16
Client-Request-Id:
- - f04d52dd-14d7-44bb-9f5c-b472dbf0b7a8
+ - fea83d0b-352a-496c-9d2d-1e6b0dbc1e16
X-Ms-Ags-Diagnostic:
- - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"5","ScaleUnit":"005","RoleInstance":"FR3PEPF0000045F"}}'
+ - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"4","ScaleUnit":"005","RoleInstance":"FR3PEPF000002C3"}}'
Date:
- - Tue, 30 Jan 2024 11:55:54 GMT
+ - Thu, 25 Apr 2024 13:51:28 GMT
body:
encoding: UTF-8
string: '{"@odata.context":"https://graph.microsoft.com/v1.0/$metadata#Collection(driveItem)/$entity","@odata.etag":"\"{3D884033-B88B-4195-8F36-D30B41AB9234},6\"","createdBy":{"user":{"email":"[email protected]","id":"0a0d38a9-a59b-4245-93fa-0d2cf727f17a","displayName":"Eric
Schubert"}},"id":"01AZJL5PJTICED3C5YSVAY6NWTBNA2XERU","lastModifiedBy":{"user":{"email":"[email protected]","id":"0a0d38a9-a59b-4245-93fa-0d2cf727f17a","displayName":"Eric
Schubert"}},"name":"Document.docx","parentReference":{"driveType":"documentLibrary","driveId":"b!dmVLG22QlE2PSW0AqVB7UOhZ8n7tjkVGkgqLNnuw2OBb-brzKzZAR4DYT1k9KPXs","id":"01AZJL5PMAXGDWAAKMEBALX4Q6GSN5BSBR","name":"Folder","path":"/drives/b!dmVLG22QlE2PSW0AqVB7UOhZ8n7tjkVGkgqLNnuw2OBb-brzKzZAR4DYT1k9KPXs/root:/Folder","siteId":"1b4b6576-906d-4d94-8f49-6d00a9507b50"},"file":{"hashes":{"quickXorHash":"unQc+b2OwmpXiE0xrwtDf4g4ZjI="},"mimeType":"application/vnd.openxmlformats-officedocument.wordprocessingml.document"},"fileSystemInfo":{"createdDateTime":"2023-09-26T14:40:58Z","lastModifiedDateTime":"2023-09-26T14:42:03Z"},"size":22514}'
- recorded_at: Tue, 30 Jan 2024 11:55:54 GMT
+ recorded_at: Thu, 25 Apr 2024 13:51:29 GMT
- request:
method: get
uri: https://graph.microsoft.com/v1.0/drives/b!dmVLG22QlE2PSW0AqVB7UOhZ8n7tjkVGkgqLNnuw2OBb-brzKzZAR4DYT1k9KPXs/items/not_existent?$select=id,name,fileSystemInfo,file,folder,size,createdBy,lastModifiedBy,parentReference
@@ -55,11 +159,112 @@ http_interactions:
Authorization:
- Bearer <BEARER TOKEN>
User-Agent:
- - httpx.rb/1.2.1
+ - httpx.rb/1.2.4
+ Accept:
+ - "*/*"
+ Accept-Encoding:
+ - gzip, deflate
+ response:
+ status:
+ code: 404
+ message: Not Found
+ headers:
+ Cache-Control:
+ - no-store, no-cache
+ Content-Type:
+ - application/json; charset=utf-8
+ Content-Encoding:
+ - gzip
+ Vary:
+ - Accept-Encoding
+ Strict-Transport-Security:
+ - max-age=31536000
+ Request-Id:
+ - c0a2affb-624f-44b7-9e57-8bc2fdfcbe7f
+ Client-Request-Id:
+ - c0a2affb-624f-44b7-9e57-8bc2fdfcbe7f
+ X-Ms-Ags-Diagnostic:
+ - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"4","ScaleUnit":"005","RoleInstance":"FR3PEPF00000366"}}'
+ Date:
+ - Thu, 25 Apr 2024 13:51:28 GMT
+ body:
+ encoding: UTF-8
+ string: '{"error":{"code":"itemNotFound","message":"Item not found"}}'
+ recorded_at: Thu, 25 Apr 2024 13:51:29 GMT
+- request:
+ method: post
+ uri: https://login.microsoftonline.com/4d44bf36-9b56-45c0-8807-bbf386dd047f/oauth2/v2.0/token
+ body:
+ encoding: ASCII-8BIT
+ string: grant_type=client_credentials&scope=https%3A%2F%2Fgraph.microsoft.com%2F.default+offline_access&client_id=4262df2b-77bb-49c2-a5df-28355da676d2&client_secret=Vwk8Q%7EJTuPh.pAjvPiWBQBdTFMDK%7EAIwxbj9_axB
+ headers:
+ User-Agent:
+ - httpx.rb/1.2.4
+ Accept:
+ - "*/*"
+ Accept-Encoding:
+ - gzip, deflate
+ Content-Type:
+ - application/x-www-form-urlencoded
+ Content-Length:
+ - '201'
+ response:
+ status:
+ code: 200
+ message: OK
+ headers:
+ Cache-Control:
+ - no-store, no-cache
+ Pragma:
+ - no-cache
+ Content-Type:
+ - application/json; charset=utf-8
+ Expires:
+ - "-1"
+ Strict-Transport-Security:
+ - max-age=31536000; includeSubDomains
+ X-Content-Type-Options:
+ - nosniff
+ P3p:
+ - CP="DSP CUR OTPi IND OTRi ONL FIN"
+ X-Ms-Request-Id:
+ - cdc3f5fe-4f4c-4123-8821-1c1dc262dc00
+ X-Ms-Ests-Server:
+ - 2.1.17846.6 - SEC ProdSlices
+ X-Ms-Srs:
+ - 1.P
+ X-Xss-Protection:
+ - '0'
+ Set-Cookie:
+ - fpc=AinSItHZvHpPhPx_Ohm_iySkbDoXAQAAAOFWvN0OAAAA; expires=Sat, 25-May-2024
+ 13:51:29 GMT; path=/; secure; HttpOnly; SameSite=None, x-ms-gateway-slice=estsfd;
+ path=/; secure; samesite=none; httponly, stsservicecookie=estsfd; path=/;
+ secure; samesite=none; httponly
+ Date:
+ - Thu, 25 Apr 2024 13:51:28 GMT
+ Connection:
+ - close
+ Content-Length:
+ - '1740'
+ body:
+ encoding: UTF-8
+ string: '{"token_type":"Bearer","expires_in":3599,"ext_expires_in":3599,"access_token":"<ACCESS_TOKEN>"}'
+ recorded_at: Thu, 25 Apr 2024 13:51:29 GMT
+- request:
+ method: get
+ uri: https://graph.microsoft.com/v1.0/drives/b!dmVLG22QlE2PSW0AqVB7UOhZ8n7tjkVGkgqLNnuw2OBb-brzKzZAR4DYT1k9KPXs/items/not_existent?$select=id,name,fileSystemInfo,file,folder,size,createdBy,lastModifiedBy,parentReference
+ body:
+ encoding: US-ASCII
+ string: ''
+ headers:
+ User-Agent:
+ - httpx.rb/1.2.4
Accept:
- "*/*"
Accept-Encoding:
- gzip, deflate
+ Authorization:
+ - Bearer <BEARER TOKEN>
response:
status:
code: 404
@@ -67,8 +272,6 @@ http_interactions:
headers:
Cache-Control:
- no-store, no-cache
- Transfer-Encoding:
- - chunked
Content-Type:
- application/json; charset=utf-8
Content-Encoding:
@@ -78,15 +281,15 @@ http_interactions:
Strict-Transport-Security:
- max-age=31536000
Request-Id:
- - ba0accac-f9f1-46cb-932e-b51529530b67
+ - f29d4c34-af1e-4beb-9dbc-d11fc3768b6a
Client-Request-Id:
- - ba0accac-f9f1-46cb-932e-b51529530b67
+ - f29d4c34-af1e-4beb-9dbc-d11fc3768b6a
X-Ms-Ags-Diagnostic:
- - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"5","ScaleUnit":"005","RoleInstance":"FR3PEPF0000036B"}}'
+ - '{"ServerInfo":{"DataCenter":"Germany West Central","Slice":"E","Ring":"4","ScaleUnit":"005","RoleInstance":"FR3PEPF00000538"}}'
Date:
- - Tue, 30 Jan 2024 11:55:54 GMT
+ - Thu, 25 Apr 2024 13:51:29 GMT
body:
encoding: UTF-8
string: '{"error":{"code":"itemNotFound","message":"Item not found"}}'
- recorded_at: Tue, 30 Jan 2024 11:55:54 GMT
+ recorded_at: Thu, 25 Apr 2024 13:51:29 GMT
recorded_with: VCR 6.2.0